This thesis details the mechanisms for sodium insertion into different carbons using both electrochemical and vapour techniques. Room temperature electrochemical measurements were completed to examine the insertion and removal of sodium from soft (graphitizable) and nanoporous hard (non-graphitizable) carbons prepared by the heat treatment of organic precursors to a range of temperatures. The mechanisms identified from these studies were further investigated through a series of in situ x-ray scattering studies on operating electrochemical cells. The results obtained were then compared with x-ray scattering measurements on carbons after exposure to sodium vapour at 890C.