The HighPGibbs program is designed to calculate thermodynamic equilibrium of fluid-rock systems up to depths of lithospheric mantle. It uses the Gibbs free energy minimization function of the HCh package to calculate mineral-fluid equilibrium. Chemical potentials of minerals are calculated using the equations of states included in HCh; free energy of aqueous species is calculated using the Deep Earth Water model; and activity coefficients of charged species are estimated using the Davies variant of the Debye-Hückel equation. HighPGibbs was applied to calculate nitrogen speciation in eclogite-buffered fluids from 400 to 790°C and 30 to 54 kbar, to evaluate the mobility of nitrogen in subducting oceanic crust. Regardless of whether the protolith was altered (and oxidized) or not, N 2 (aq) or NH 3 (aq) is the predominant form of nitrogen in the slab fluids at subarc temperatures, especially in cases of moderate or hot geotherms. Given that molecular nitrogen is highly incompatible in silicate minerals, the simulation indicates that nitrogen (as NH 4 + ) in silicate minerals can be liberated during metamorphic devolatilization. The majority of nitrogen in subducting crusts can be unlocked during slab devolatilization and eventually expelled to the atmosphere via degassing of arc magmas. Therefore, oceanic crusts recycled to deep Earth will be depleted in nitrogen compared to the newly formed crust at spreading centers. As a result of the long-term mantle convection, large proportions of the bulk silicate Earth may have suffered nitrogen extraction via subduction, and this may account for the nitrogen enrichment in the Earth's atmosphere.Plain Language Summary Thermodynamic simulation is a powerful tool for investigating the geochemistry of fluid-rock systems. Such simulations are difficult to perform when pressures are higher than 5 kbar. We present a practical tool, HighPGibbs, that can calculate chemical equilibrium at pressures up to~55 kbar and can be used to predict the behavior of mantle fluids. It was applied to calculate the speciation of nitrogen in subduction zone fluids. The simulations show that molecular nitrogen, which is incompatible in crustal rocks, predominates in most subduction zone fluids. Therefore, most nitrogen in the subducting crusts can be unlocked by the fluids and eventually released to the atmosphere via degassing of arc magmas.