Melatonin (MT) has been implicated in the plant response to phosphorus (P) stress; however, the precise molecular mechanisms involved remain unclear. This study investigated whether MT controls internal P distribution and root cell wall P remobilization in rice. Rice was treated with varying MT and P levels and analyzed using biochemical and molecular techniques to study phosphorus utilization. The results demonstrated that low P levels lead to a rapid increase in endogenous MT levels in rice roots. Furthermore, the exogenous application of MT significantly improved rice tolerance to P deficiency, as evidenced by the increased biomass and reduced proportion of roots to shoots under P‐deficient conditions. MT application also mitigated the decrease in P content regardless in both the roots and shoots. Mechanistically, MT accelerated the reutilization of P, particularly in the root pectin fraction, leading to increased soluble P liberation. In addition, MT enhanced the expression of OsPT8, a gene involved in root‐to‐shoot P translocation. Furthermore, we observed that MT induced the production of nitric oxide (NO) in P‐deficient rice roots and that the mitigating effect of MT on P deficiency was compromised in the presence of the NO inhibitor, c‐PTIO, implying that NO is involved in the MT‐facilitated mitigation of P deficiency in rice. Overall, our findings highlight the potential of MT as a promising strategy for enhancing rice tolerance to P deficiency and improving P use efficiency in agricultural practices.