Phosphorus is an important element believed to be present in the Earth's core. As a non-metal, its solubility in iron is limited, leading to the precipitation of phosphides at high concentrations. Here we present experimental results for the iron-rich portions of the Fe-P and Fe-P-S systems at 23 GPa. We find a Fe-P eutectic point occurring at 9 wt% P and 1275°C at 23 GPa. Up to 4 wt% P is soluble in the Fe-rich solid coexisting with the eutectic liquid at these conditions. The ternary Fe-P-S system displays a simple cotectic between the Fe-P and Fe-S binary eutectics with minimum melting temperature on the S-side at 1075°C. At subsolidus conditions there is complete solid solution between Fe3P and Fe3S. The high solubility of phosphorus in iron along with its miscibility in Fe3S and iron-sulfur liquids at high pressures, combined with expectation of only minor concentrations in planetary cores, indicate phosphorus will not form a distinct phase within terrestrial planet cores.