Understanding what governs the speciation in the C-O-H-N system aids our knowledge of how volatiles affect mass transfer processes in the Earth's interior. Experiments with aluminosilicate melt + C-O-H-N volatiles were, therefore, carried out with Raman and infrared spectroscopy to 800°C and near 700 MPa in situ in hydrothermal diamond anvil cells. The measurements were conducted in situ with the samples at the desired temperatures and pressures in order to avoid possible structural and compositional changes resulting from quenching to ambient conditions prior to analysis. Experiments were conducted without any reducing agent and with volatiles added as H 2 O, CO 2 , and N 2 because both carbon and nitrogen can occur in different oxidation states. Volatiles dissolved in melt comprise H 2 O, CO 3 2-, HCO 3 -, and molecular N 2 , whereas in the coexisting fluid, the species are H 2 O, CO 2 , CO 3 2-, and N 2 . The HCO 3 -/CO 3 2-equilibrium in melts shift toward CO 3 2-groups with increasing temperature with ΔH = 114 ± 22 kJ/mol. In fluids, the CO 2 abundance is essentially invariant with temperature and pressure. For fluid/melt partitioning, those of H 2 O and N 2 are greater than 1 with temperature-dependence that yields ΔH values of − 6.5 ± 1.5 and − 19.6 ± 3.7 kJ/mol, respectively. Carbonate groups, CO 3 2-are favored by melt over fluid. Where redox conditions in the Earth's interior exceed that near the QFM oxygen buffer (between NNO and MW buffers), N 2 is the stable nitrogen species and as such acts as a diluent of both fluids and melts. For fluids, this lower silicate solubility, in turn, enhances alkalinity. This means that in such environments, the transport of components such as high field strength cations, will be enhanced. Effects of dissolved N 2 on melt structure are considerably less than on fluid structure.