A father and his baby daughter were forced to flee a burning building in Brooklyn Wednesday evening.

The fire broke out shortly before 7:40 p.m. on the third floor of the building on 19th Avenue in Bath Beach.

The infant was checked out by paramedics as a precautionary measure.

A witness said the girl's father was asleep when he smelled smoke and ran out of the building barefoot.

"My cousins and family live on the second floor. Nothing had to do with their house, but everything was evacuated," the witness said. "The whole apartment is destroyed now. There's water damage. There's everything. There's a horrible mess. But us as a community and a block and a neighborhood did definitely all come together to help everybody out during this tragedy."

The fire was under control in about half an hour.