Two teens were charged with hate crimes after they threw a brick at a couple of men while shouting anti-gay slurs in Brooklyn, authorities said.

The victims, 26 and 25, were walking near the corner of Grand St. and Bedford Ave. in Williamsburg when the punks confronted them around 6 p.m. Monday.

One of the teens shouted “F–k you, f—-t!” before chucking the brick in the direction of the two men, striking one of them in the leg.

Police captured the pair a few blocks away and charged them each with assault as a hate crime and aggravated harassment.

Both are being charged as juveniles.