Inspired by the gradual collapse of carbon chain and the gradual release of organic elements into the external environment during the degradation of biodegradable polymers, a novel biodegradable polymer slow-release fertilizer containing nutrient nitrogen and phosphorus (PSNP) was prepared in this study. PSNP contains phosphate fragment and urea formaldehyde (UF) fragment, which are prepared by solution condensation reaction. Under the optimal process, the nitrogen (N) and P2O5contents of PSNP were 22% and 20%, respectively. The expected molecular structure of PSNP was confirmed by SEM, FTIR, XRD, and TG. PSNP can release N and phosphorus (P) nutrients slowly under the action of microorganisms, and the cumulative release rates of N and P in 1 month were only 34.23% and 36.91%, respectively. More importantly, through soil incubation experiment and leaching experiment, it was found that UF fragments released in the degradation process of PSNP can strongly complex soil high-valence metal ions, thus inhibiting the phosphorus nutrient released by degradation to be fixed in the soil and ultimately effectively increasing the soil available P content. Compared with ammonium dihydrogen phosphate (ADP), a small molecule phosphate fertilizer that is easily soluble, the available P content of PSNP in the 20–30 cm soil layer is almost twice that of ADP. Our study provides a simple copolymerization method to prepare PSNP with excellent slow-release N and P nutrients, which can promote the development of sustainable agriculture.