The blaze broke out at a vacant YWCA building located along the 5800 block of Germantown Avenue.
At 5:17 p.m., fire crews responded to the scene and reported fire and smoke coming from the third floor of the brick building.
It took crews a little more than an hour to douse the fire. The blaze was brought under control at 6:19 p.m.
The two firefighters were rushed to Albert Einstein Medical Center for what officials say were minor injuries.
There is no word on what caused the fire, but vagrancy is a problem in the building.