Wildfires release greenhouse gases, such as methane, carbon monoxide, and carbon dioxide. Once released into the atmosphere, these gases trap heat in the same way that greenhouses trap heat to cultivate plants. That's why people call this the Greenhouse Effect. By reflecting light, instead of absorbing it, aerosols have a cooling effect. But even this can't counter the warming effect of greenhouse gases.
Rain washes out aerosols from the atmosphere in a few days.
In contrast, gases can remain in the atmosphere for up to 10 years. This is crucial because it contributes to global warming.