Airplanes don’t recirculate air any more than most environments you spend time in. Despite this, people frequently claim various versions of this urban legend. Some say the air when they close the door stays in the cabin until they open it on landing. Others say it’s actually coming from air canisters stored on the aircraft. It is not true.
The air is really a 50/50 blend of recirculated air and new air bled through the engine air compressors (before combustion). The NY Times has a nice little writeup on cabin air:
Cabin air, he said, is refreshed about 15 times an hour, compared with less than 12 an hour in an office building. On most full-size jets, the air is also circulated through hospital-grade HEPA filters, which are supposed to remove 99.97 percent of bacteria and the minuscule particles that carry viruses. The cabin air is also divided into separate ventilation systems covering every seven rows or so, limiting the ability of germs to travel from one end of the plane to the other.
The reason most people feel the air quality is so low is because the humidity is about 10% to prevent corrosion of the aircraft, which is almost always metal. Newer aircraft are now being made using composites allowing for more natural humidity. The other factor is pressurizing to approx. 8,000 ft, which is higher than you’re used to.
Those HEPA filters employed are also more than adequate to filter air leaving it cleaner than most homes [pdf].
Presumably the confusion is aided by the emergency oxygen system on board modern airliners.
So next time someone claims that the air is literally unchanged through a 9 hour flight, you should call their bluff and ask for documentation. This has been a pet peeve of mine.