Respiratory failure happens when not enough oxygen passes from your lungs into your blood. Your body's organs, such as your heart and brain, need oxygen-rich blood to work well. Respiratory failure also can happen if your lungs can't remove carbon dioxide (a waste gas) from your blood. Too much carbon dioxide in your blood can harm your body's organs.
Diseases and conditions that affect your breathing can cause respiratory failure. Examples include
Treatment for respiratory failure depends on whether the condition is acute (short-term) or chronic (ongoing) and how severe it is. It also depends on the underlying cause. You may receive oxygen therapy and other treatment to help you breathe.
NIH: National Heart, Lung, and Blood Institute