According to ChemGuard, a foam fire extinguisher sprays a foam containing water, foam concentrate and air. The foam concentrate comes in several forms, such as fluoroproteins, proteins and detergents.
MFS Fire indicates that foam extinguishers are appropriate for putting out Class A and Class B fires. Class A fires, which burn solids like paper, wood and plastic, respond well to both foam and water. Class B fires are caused by flammable liquids, including paraffin, gasoline and oil, which float on water but are extinguished by foam. Foam extinguishers are not used for electrical fires. However, foam does not cause as many problems as water does if it accidentally comes in contact with electricity.