Perovskite solar cells (PSCs) suffer from significant nonradiative recombination, limiting their power conversion efficiencies. Here, for the first time, we directly observe a complete transformation of perovskite MAPbI3 surface region energetics from p- to n-type during defect passivation caused by natural additive capsaicin, attributed to the spontaneous formation of a p-n homojunction in perovskite active layer. We demonstrate that the p-n homojunction locates at ∼100 nm below perovskite surface. The energetics transformation and defect passivation promote charge transport in bulk perovskite layer and at perovskite/PCBM interface, suppressing both defect-assisted recombination and interface carrier recombination. As a result, an efficiency of 21.88% and a fill factor of 83.81% with excellent device stability are achieved, both values are the highest records for polycrystalline MAPbI3 based p-i-n PSCs reported to date. The proposed new concept of synergetic defect passivation and energetic modification via additive provides a huge potential for further improvement of PSC performance.