It happened at the 32nd Street Pub at 32nd Street and Allegheny Avenue around 12:45 a.m. Friday.
Witnesses say the gunman and the 33-year-old victim were talking inside, then the victim walked out a side door to leave.
The gunman came up behind him, shot him in the head and neck, then fled in an SUV.
Officers rushed the victim to the hospital, but they're not sure if he'll survive.
Police say the shooter was wearing a pink or light-colored baseball cap and possibly a green jacket.
SEE ALSO: 2 dead after car hits home in Chester, Pa. and bursts into flames