Despite living in water, fishes need oxygen to live. Unlike land-dwellers, though, they must extract this vital oxygen from water, which is over 800 times as dense as air. This requires very efficient mechanisms for extraction and the passage of large volumes of water (which contains only about 5% as much oxygen as air) over the absorption surfaces.
To achieve this, fishes use a combination of the mouth (buccal cavity) and the gill covers and openings (opercula). Working together, these form a sort of low-power, efficient pump that keeps water moving over the gas absorption surfaces of the gills.
The efficiency of this system is improved by having a lot of surface area and very thin membranes (skin) on the gills. However, these two features also increase problems with osmoregulation, as they also encourage water loss or intake. Consequently, every species must trade off some respiratory efficiency as a compromise for proper osmoregulation.
Blood passing through the gills is pumped in the opposite direction to the water flowing over these structures to increase oxygen absorption efficiency. This also ensures that the blood oxygen level is always less than the surrounding water, to encourage diffusion. The oxygen itself enters the blood because there is less concentration in the blood than in the water: it passes through the thin membranes and is picked up by hemoglobin in red blood cells, then transported throughout the fish’s body.
As the oxygen is carried through the body, it diffuses into the appropriate areas because they have a higher concentration of carbon dioxide. It is absorbed by the tissues and used in essential cell functions.
The carbon dioxide is produced as a by-product of metabolism. Since it is soluble, it diffuses into the passing blood and is carried away to eventually be diffused through the gill walls. Some of the carbon dioxide may be carried in the blood as bicarbonate ions, which are used as part of osmoregulation by trading the ions for chloride salts at the gills.