Nuclear magnetic resonance spectroscopy with magic angle spinning (MAS n.m.r.) has been used to study the chemical environments of sodium, aluminium, silicon, phosphorus and boron in coal. The 23Na MAS n.m.r. spectra of the raw coals show the sodium to be fully hydrated, and organically bound. There was little evidence for NaCl. The 27Al spectra show aluminium in both octahedral and tetrahedral coordination, indicative of the varying proportions of the different clay minerals in the coals. These are reflected in the 29Si spectra, which also show a quartz resonance. The 31P spectra suggest that phosphorus in coal is present largely as apatite. The 11B spectra exhibit trigonal or tetrahedral resonances. Trigonal boron is probably due to tourmaline, but the tetrahedral form could not be reliably assigned; it may be held in tetrahedral sites within the potassium clays. The transformations of these elements in combustion processes have been elucidated by further MAS n.m.r. studies of ashes and boiler deposits. Boron phosphate has been shown to be a major component of bonded deposits formed when high-phosphorus coals are burned in certain stoker-fired appliances.