One of the major things that keep us from colonizing space is oxygen. Other planets don't have that much of it, and we really need it. But when did we first learn exactly what it took to keep us breathing?
Human beings have had a notion that it takes more than just "air" to keep them alive ever since they discovered fire. It probably didn't take too long for them to understand that a fire in an enclosed space didn't really use up the air itself, but certainly used up something in the air that they desperately needed. They might have even known that too many people breathing in an enclosed space would do the same. But it took a surprisingly long time to separate oxygen from all the other parts of air that don't keep us alive.
Oxygen has a complicated parentage, with multiple scientists discovering more or less independently around the same time period. Only one of those three, Joseph Priestley, made the connection between oxygen and living organisms, though. He was also the inventor of laughing gas, and tested many of the various chemicals he created or liberated on himself first, so he may have noticed himself energized after an extended period of exposure to high levels of oxygen. Perhaps that's why he chose to push the experiment further.
The newly liberated gas, which he made by exposing mercuric oxide to sunlight, he called dephlogisticated air. Being a reckless early chemist, he decided to pump some of this air into a container with a candle. The candle burned brighter. He pumped it into areas with mice, and noticed that the mice were more lively and lived longer. The connection between the candle flame and the living beings was made, he published his results in 1775, and at last the population of the world knew exactly what it had been breathing all this time.