Most smoke detectors have a 9 volt battery in them. The rule is to replace them when the time changes on daylight savings time. I have found some detectors that have a one time 10 year battery that is sealed in the unit. That prevents the chance of pulling out the battery if your detector keeps going off such as burning your supper. You can also buy a 10 year battery made for this use.
I know how quick it can happen to pull the battery out. We responded to a 3:00am fire call where the battery was on the kitchen table. A father and a son died in this fire.
As result of this fire, I wrote a grant for $25,000 to purchase 1600 smoke detectors to give away in our community to prevent this from ever happening in our community again.