As a hazard
Fire is capable of destroying crops, resources, structures, and can injure or kill pawns. It spreads via embers that travel up to two tiles and will start another fire if it lands on something flammable. Fire may spread far and wide if left unchecked. Colonists capable of firefighting will only fight fires in your Home area. To make them fight fires outside of this area, use the "Expand home area" tool in the Zone/Area section of the Architect menu.
A good way to prevent fire from spreading is by using firebreaks. Firebreaks are non-flammable flooring, typically stone, with a minimum width of three tiles. Place firebreaks outside of colony perimeter walls and around other important structures. Another key step to preventing fire is to use non-flammable materials for walls.
Pawns on fire will become momentarily disabled by panic and will attempt to extinguish the fire. They may also wander into unsafe open areas where they might be vulnerable to attacks. Pawns on fire can also spread fire.
At higher temperatures (~235C/455F/508K), flammables can spontaneously ignite, and an orange haze effect will appear. Pawns trying to put out the fire may collapse from heatstroke. To prevent pawns from succumbing to the heat in an enclosed room, simply remove some of the roof, and then tend to the fire.
Objects and structures on fire will take damage to their hit points over time. The damage taken value is the same for everything. The size of the fire depends on the flammability of the material. Objects with 0% flammability can't catch fire.
As a tool or weapon
Countermeasure against infestations
Infestations are difficult to clear, especially when spread through multiple (mined out) caves.
An effective method is to equip a colonist with an incendiary launcher or molotov cocktails and attack the hives one at a time.
Should one of your caves have power conduits running through all the area and completely sealed with roof, they could be used to spread the fire by closing the caves with walls and then simply shoot at a conduit to ignite. Insectoids will collapse and eventually die of burns or heatstroke, hives will ignite if the temperature gets high enough for spontaneous combustion.
A faster alternative to "Cut plants" to clear areas from vegetation that provides a tactical defense as it takes any possible cover object away from enemies. Equip an incendiary launcher or molotov cocktail and target to attack the desired area. The fire will spread rapidly in all directions, so the player must ensure there are no flammables near unintended sections. Rain will extinguish fire on unroofed areas.