Here, we report experimental results on melting and subsolidus phase relations in the Fe–Fe2P system at 6 GPa and 900–1600°C. The system has two P-bearing compounds: Fe3P and Fe2P. X-ray diffraction patterns of these compounds correspond to schreibersite and barringerite, respectively. The Fe–Fe3P eutectic appears at 1075°C and 16 mol% P. Schreibersite (Fe3P) melts incongruently at 1250°C to produce barringerite (Fe2P) and liquid containing 23 mol% P. Barringerite (Fe2P) melts congruently at 1575°C. Maximum solid solution of P in metallic iron at 6 GPa is 5 mol%. As temperature increases to 1600°C, the P solubility in the metallic iron decreases to 0.5 mol%, whereas the P content in coexisting liquid decreases to 3 mol%. The composition of quenched phases from Fe–P melt coincides with the compositions of equilibrium phases at corresponding temperature. Consequently, the composition of quenched products of Fe-P melts in meteorites can be used for reconstruction of P–T conditions of their crystallization under ambient or low pressures or during shock melting by impact collisions.