2 NaN3 (s) → 2 Na (s) + 3 N2 (g)
In this reaction, sodium azide decomposes upon heating to produce elemental sodium and nitrogen gas. The sodium metal instantly reacts with any available moisture to form sodium hydroxide (NaOH) and hydrogen gas (H2).
2 Na (s) + 2 H2O (l) → 2 NaOH (aq) + H2 (g)
The rapid production of nitrogen gas (N2) and hydrogen gas (H2) inflates the airbag, providing a cushion for the vehicle occupants during a collision.