A man was shot once in the back in Brooklyn on Monday morning, more than an hour after the annual J’Ouvert festival kicked off, police said.

Gunfire erupted outside 706 Nostrand Ave., between St. Marks Avenue and Prospect Place, around 7:35 a.m., according to cops.

The gunman took off on foot southbound on Nostrand and was last seen wearing a black shirt.

“I heard one shot,” said a witness, who didn’t want to be named. “I said, ‘Oh sh-t! What was that?’ It was that loud. A lady was running, she was moving very fast. She was scared.”

The victim was taken to Kings County Hospital but is expected to survive.

“He was on his back. His arms were above his head, kind of flared out,” the witness added about watching as the victim was placed on a stretcher.

Two women were also injured by gunfire in the hours before J’Ouvert.

A 26-year-old woman was shot in the elbow and a 29-year-old woman was grazed in the leg at 668 Flatbush Ave. at 2:25 a.m. Both were taken to Kings County Hospital with non-life-threatening injuries.

The Nostrand shooting occurred several blocks north of the official J’Ouvert parade route, which concludes at Nostrand and Rutland Road. For the second year in a row, the festivities began at 6 a.m. and will go until about 11 a.m. — when the West Indian Day Parade gets under way.

Violence has plagued the J’Ouvert celebrations in past years. In 2016, two people were fatally gunned down, and the year before, Gov. Andrew Cuomo aide Carey Gabay was killed in the crossfire between two rival gangs.