The lungs are the organs that bring oxygen into the body and remove carbon dioxide from it. Every cell needs oxygen to release energy from nutrients, while carbon dioxide is a waste product that must be continuously cleared from the bloodstream.
Breathing makes this exchange possible, but the lungs do more than simply move air in and out. A coordinated system of airways, muscles, blood vessels, and microscopic air sacs moves air deep into the lungs, transfers gases between air and blood, and helps regulate the body’s acid-base balance.
What happens when you breathe?
Air normally enters through the nose or mouth and travels down the throat into the windpipe, or trachea. The trachea divides into two main bronchi, one leading to each lung. Inside the lungs, these airways branch repeatedly into smaller tubes called bronchioles.
At the ends of the smallest bronchioles are millions of microscopic air sacs called alveoli. Their walls are extremely thin and are surrounded by tiny blood vessels called capillaries. This close contact between air and blood is where most gas exchange occurs.
When you inhale, the chest expands and air flows into the lungs. When you exhale, the chest returns toward its resting position and air flows back out. The movement itself is driven mainly by the diaphragm, a broad, dome-shaped muscle beneath the lungs, along with muscles between the ribs.
The lungs do not actively pump air in and out like a mechanical pump. Instead, the breathing muscles change the size and pressure of the chest cavity, causing air to flow because of pressure differences.
How inhalation and exhalation work
The diaphragm is the most important muscle used during quiet breathing. When it contracts, it moves downward and becomes flatter. This increases the volume of the chest cavity. Because the lungs are enclosed within the chest and normally follow these movements, pressure inside the lungs falls slightly below atmospheric pressure, and air flows inward.
During relaxed exhalation, the diaphragm stops contracting and returns toward its dome-shaped resting position. The elastic tissues of the lungs and chest wall help reduce lung volume, raising the pressure inside the lungs and pushing air outward.
More forceful breathing recruits additional muscles. During vigorous exercise or other situations in which ventilation must increase, muscles of the chest and abdomen can contribute to stronger inhalation and exhalation.
A thin, slippery membrane called the pleura surrounds each lung. The pleural layers allow the lungs to move smoothly against the chest wall while helping keep the lungs mechanically coupled to the expanding and contracting chest.
How oxygen gets into the blood
The air reaching the alveoli contains oxygen. The blood arriving at the lung capillaries has relatively little oxygen and a higher concentration of carbon dioxide because it has circulated through the body’s tissues.
Oxygen therefore moves from the air in the alveoli across the thin alveolar and capillary walls and into the blood. This movement is a form of diffusion: molecules move across a barrier from an area where their concentration or partial pressure is higher toward an area where it is lower.
Most oxygen in the blood then binds to hemoglobin, a protein inside red blood cells. Hemoglobin acts as the main carrier that transports oxygen through the circulation to tissues throughout the body.
For gas exchange to work efficiently, two things must happen together: air must reach the alveoli, and blood must reach their surrounding capillaries. This matching of ventilation and blood flow is known as ventilation-perfusion matching. Areas of the lung that receive air but relatively little blood, or blood but relatively little air, exchange gases less efficiently.
How the lungs remove carbon dioxide
The process also works in the opposite direction.
Blood returning from the body’s tissues carries carbon dioxide produced by cellular metabolism. Carbon dioxide moves from the blood into the alveoli, where it becomes part of the air that is exhaled.
Carbon dioxide is especially important because it affects the acidity of the blood. The body converts carbon dioxide and water into carbonic acid through a reversible chemical reaction. As carbon dioxide builds up, blood becomes more acidic; when carbon dioxide is removed through breathing, acidity decreases.
This is why breathing is closely connected to the body’s acid-base balance, not just its oxygen supply.
Why the alveoli are so effective at gas exchange
The lungs are designed to make diffusion rapid. The alveoli provide a very large surface through which gases can pass, their walls are extremely thin, and a dense network of capillaries brings blood close to the alveolar air.
The alveoli also contain a substance called surfactant. It reduces surface tension inside the air sacs and helps prevent them from collapsing, particularly during exhalation. Without adequate surfactant, keeping the alveoli open would require substantially more effort.
The airways have additional defenses. The nose helps filter, warm, and humidify incoming air. Mucus traps particles, while tiny hairlike structures called cilia move mucus toward the throat, where it can be swallowed or expelled. Coughing and other airway reflexes provide further protection.
How the brain controls breathing
You do not normally have to consciously remind yourself to breathe. Breathing is largely controlled automatically by networks in the brainstem.
These control systems continuously receive information about conditions inside the body, especially levels of carbon dioxide and the resulting changes in blood acidity. When carbon dioxide rises, the brain increases the drive to breathe, causing breathing to become faster or deeper and helping remove the excess carbon dioxide.
Sensors called chemoreceptors contribute to this regulation. The body also responds to changes in oxygen, although under ordinary conditions carbon dioxide and acidity are particularly important signals for controlling ventilation.
Breathing can also be modified voluntarily. You can hold your breath, speak, sing, or deliberately change your breathing pattern. Voluntary control, however, operates alongside the brain’s automatic systems, which continue monitoring the body’s need for ventilation.
What determines how much air reaches the lungs?
Not every breath contributes equally to gas exchange. Some inhaled air remains in the conducting airways, such as the trachea and bronchi, where it does not directly participate in gas exchange. This portion is called anatomic dead space.
The amount of useful ventilation therefore depends on both breathing frequency and the depth of each breath. Very shallow, rapid breaths can devote a larger fraction of each breath to the conducting airways, leaving less fresh air reaching the alveoli.
During exercise, breathing normally becomes both deeper and faster. At the same time, blood flow through the lungs increases, allowing oxygen delivery and carbon dioxide removal to rise with the body’s metabolic demands.
What happens to the oxygen after it leaves the lungs?
Once oxygen enters the blood, the heart pumps oxygen-rich blood through the arteries to the body’s tissues. Oxygen leaves the blood and enters cells, where it is used in cellular respiration to help produce usable energy.
The carbon dioxide generated by those cells travels in the opposite overall direction: it enters the blood, is transported back to the lungs, diffuses into the alveoli, and leaves the body when you exhale.
The lungs and cardiovascular system therefore function as a single transport-and-exchange system. The lungs load blood with oxygen and remove carbon dioxide; the heart and blood vessels distribute that blood throughout the body and return it to the lungs.
Why healthy lungs need both airflow and blood flow
Efficient breathing depends on more than having open airways. Oxygen can reach the alveoli but still fail to enter the blood effectively if blood flow is severely reduced. Conversely, blood can pass through lung capillaries without gaining enough oxygen if air is not reaching the corresponding alveoli.
This distinction helps explain why different lung and circulatory problems can produce similar symptoms. An airway obstruction primarily interferes with airflow. A problem affecting the lung’s air sacs can interfere with gas exchange. A circulation problem can limit the blood available to receive oxygen.
The lungs are therefore best understood not as simple air containers, but as highly organized organs that continuously coordinate ventilation, diffusion, and blood flow.
How the lungs stay open
Lung tissue contains elastic fibers that allow the lungs to stretch during inhalation and recoil during exhalation. The relationship between the lungs and chest wall also helps maintain their expanded state.
The pleural space between the two pleural layers contains a small amount of lubricating fluid. Pressure within this space is normally lower than atmospheric pressure. This pressure relationship helps keep the lungs expanded against the inside of the chest wall.
The surfactant lining the alveoli provides another important safeguard against collapse. Together, these mechanical features allow the lungs to expand and recoil repeatedly with relatively little effort.
The lungs do more than exchange gases
Gas exchange is the lungs’ central job, but lung tissue also performs other functions. Blood passing through the pulmonary circulation encounters the lung’s extensive vascular network, where certain substances are modified or broken down and others are released into or taken up from the blood.
The lungs also help protect the body from inhaled particles and microorganisms through mucus, cilia, immune cells, airway reflexes, and other defenses.
Most importantly, their continuous exchange of oxygen and carbon dioxide links breathing directly to every tissue in the body. With each breath, the lungs adjust the composition of the air reaching the alveoli; with each circulation through the pulmonary capillaries, blood is prepared to deliver oxygen and carry metabolic waste back for removal.

