BOSTON (CBS) – An elderly man jumped from a second story window to escape a fire in Dorchester Thursday afternoon.

The fire trapped the man on the second floor of a home on Bowdoin St. He was able to get out thanks to several men who were at a nearby barbershop, saw the flames and ran over to help.

READ MORE: 4 Democrats, One Republican Have Announced Candidacy For Massachusetts Governor In 2022

Cell phone video shows the man getting out of the window and being pulled to safety by one of those good Samaritans.

A group helps rescue an elderly man from a burning building in Dorchester (Photo Credit Edwin Castro)

With only seconds to react, several others huddled together on the ground. The man fell and those on the ground caught him, dragging him away from the house before the flames spread.

There was three people in the home at the time. Two of them, including the man who jumped out the window, were taken to the hospital with smoke inhalation.

READ MORE: Gov. Charlie Baker: Decision Not To Run For Third Term Was 'Complicated And Difficult'

The scene of a Dorchester house fire. (WBZ-TV)

The third person living in the home refused medical treatment.

“You could see the flames from a block away,” said Denise Williams. “It was black puffs of smoke, and the house went up very quickly, very quickly.”

The fire caused about $500,000 in damage. The cause of the fire is under investigation.

MORE NEWS: Massachusetts Reports 4,838 New COVID-19 Cases, 25 Additional Deaths