Niobium (Nb) is one of the key trace elements used to understand Earth's formation and differentiation, and is remarkable for its deficiency relative to tantalum in terrestrial rocks compared to the building chondritic blocks. In this context, the local environment of Nb in silica-rich melts and glasses is studied by in situ x-ray absorption spectroscopy (XAS) at high pressure (P) up to 9.3 GPa and 1350 K using resistive-heating diamond-anvil cells. Nb is slightly less oxidized in the melt (intermediate valence between +4 and +5) than in the glass (+5), an effect evidenced from the shift of the Nb-edge towards lower energies. Changes in the pre-edge features are also observed between melt and glass states, consistently with the observed changes in oxidation state although likely enhanced by temperature (T) effects. The oxidation state of Nb is not affected by pressure neither in the molten nor glassy states, and remains constant in the investigated P-range. The Nb-O coordination number is constant and equal to [Formula: see text] below 5 GPa, and only progressively increases up to [Formula: see text] at 9.3 GPa, the maximum P investigated. If these findings were to similarly apply to basaltic melts, that would rule out the hypothesis of Nb/Ta fractionation during early silicate Earth's differentiation, thus reinforcing the alternative hypothesis of fractionation during core formation on reduced pre-planetary bodies.