Operating engines consumes fuel, delivers useful work and produces emissions. Left uncontrolled, those emissions can produce blankets of smog that nobody wants. Using less gas will also produce less pollution. Pollution levels are also controlled by use of emission reduction technologies and fuels. What is in the emissions coming out of your tailpipe? You will find that almost all of them are one of the following five things.
Hydrocarbons CnHm: these are the fuel itself. If the fuel is not completely burned up in the combustion process, whatever is left over must come out the tailpipe. Engines running rich (with excess fuel relative to the amount of air in the cylinder) will emit hydrocarbons. It is also possible to find hydrocarbons in the exhaust if the engine is running very lean (excess air relative to fuel) because sometimes under lean conditions the combustion does not get going at all or does not complete, leaving fuel in the exhaust.
These hydrocarbons are the dominant component in ground hugging smog. Mixed with nitrogen oxides
in the sunlight they combine to form ozone. Low level ozone is a health hazard.
Carbon Dioxide CO2: completely burned fuel. Thermodynamics shows us that the most stable combination of Carbon and Oxygen is as carbon dioxide. Thus whenever possible combustion continues to this stage.
Carbon dioxide has no adverse health effects but famously contributes to global climate change. One of the big villains on an international scale.
Carbon Monoxide CO: incompletely burned fuel. Combustion favors the attachment of two Oxygen atoms to each Carbon atom. In rich conditions there might not be enough Oxygen to go around. Thus CO will tend to be produced in rich burn and very little or none will be produced in lean conditions.
Carbon Monoxide is poisonous. Not a good thing.
Oxygen O2 : from incompletely burned air. Just as running rich can leave some fuel unburned in the combustion process, running lean can leave unburned Oxygen.
This oxygen was in the air anyway before it got ingested into your engine. So this one is no problem.
Nitrogen Oxides NOx : from the combustion of the Nitrogen in the air. Air is a mixture of gases containing about 70% N2. At high temperatures some of this reacts with the Oxygen in the cylinders producing NOx.
NOx is a health hazard. They cause lung damage in low concentrations and can be outright fatal at high concentrations. They also corrode metals, eat away at fabrics and kill plants.
Just think: when you reduce gas consumption, you also reduce production of all of these emissions. Yet more reasons to save on gas! Better gas mileage helps a lot more than just your wallet.