Fire officials in Brunswick are crediting smoke detectors and a vigilant homeowner with finding a fire before it spread through a farmhouse early Monday morning.

A man was awake watching television at 29 Merryman Lane shortly before 3 a.m. when he smelled smoke. As he went to wake his wife and 2-year-old son, he found the child’s bedroom filling with smoke. Smoke detectors began to sound as the man took his son out of his crib and the family left the house, said Brunswick Fire Chief Ken Brillant.

The family was out of the house by the time fire crews arrived. No one was injured.

There was no visible fire when crews got there, but smoke was filling the second floor. Crews eventually found fire smoldering in the insulation in the walls surrounding a wood stove and chimney. Knowing that breaking into the walls to get to the fire would be messy, crews removed some furniture and Christmas gifts from the living room before spreading tarps to protect the floors, Brillant said.

“(The fire) was smoldering down inside the walls. That took a little while to put out,” he said.

Brillant said the fire serves as a good example of how important it is to make sure smoke detectors are working on each floor of a house and especially near bedrooms.

“We also need to be very vigilant this time of year when you’re heating with wood to make sure fireplaces and stoves are clear of combustibles,” he said.

Fire crews from Brunswick, Topsham, Freeport and West Bath responded to the fire.