Conventional phosphorus anode materials in lithium/sodium-ion batteries are mainly based on the physical mixing and evaporation/condensation, in which external phosphorus on conductive matrix is unavoidable and hard to be removed due to the formation of crystalline phase. It has been found to break off from conductive matrix easily and deteriorate capacity rapidly. In this communication, we first report a solution processed encapsulation method which facilitates phosphorus anchored inside multi-walled carbon nanotubes (MWCNTs). Any possible external phosphorus adsorbents are hard to transform into crystalline and enable an easy removal by polar solvents. Eventually, the phosphorus rings and chains are successfully encapsulated only inside MWCNTs, exhibiting high cycling stability in lithium-ion battery because of the efficient physical confinement and unique discrete phosphorus segment assemblies inside MWCNTs which ensured enough vacant space for volume expansion.