HAYWARD — An teen used a ladder to rescue his 13-year-old brother from a burning second-story bedroom Friday night as the building quickly filled with thick black smoke, a firefighter said Saturday.

The unidentified 18-year-old smelled smoke and after jumping out of his second-story bedroom window to the grass below, he climbed an aluminum extension ladder to a different window and pulled his younger brother from his smoke-filled room. The younger boy remains hospitalized in stable condition with smoke inhalation, said Alameda County Fire Battalion Chief John Whiting.

“They’re a very nice family and I’m glad the 13-year-old is doing better,” Whiting said. “I’m glad the 18-year-old brother had the presence of mind to do what he did and potentially saved his brother’s life.”

18 yr old uses ladder to save his 13 yr old brother in #Hayward house fire. Younger son has smoke inhalation. All expected to recover. pic.twitter.com/d2sakUl9sm — Christien Kafton (@CKaftonKTVU) May 27, 2017

A total of three brothers were inside the unincorporated Hayward home on the 400 block of Cherry Way around 8:45 p.m. Friday when the one-alarm blaze broke out, Whiting said. When firefighters arrived smoke was pouring from the side of the two-story house in the Cherryland neighborhood, and the family members had already escaped.

The fire gutted the first-floor living area and the rest of the house had significant smoke damage, Whiting said. The cause of the fire is under investigation.

The boy remains hospitalized at UCSF Benioff Children’s Hospital Oakland.