Ultrathin microporous carbon (UMPC) for lithium–sulfur (Li–S) cathode with uniform pore width of approximately 0.6 nm and dozens nm in thickness is synthesized with graphene oxide as template by glucose hydrothermal carbonization and surfactant-assisted assembling method. The UMPC supplies desirable S pregnancy space and the intimate contact between UMPC and S, therefore improving the conductivity of S@UMPC composite and dynamic performance. Smaller sulfur molecules limited in UMPC thoroughly prevent the formation of electrolyte-soluble polysulfides, hence excellent cycling performance with 900 mAh g−1 after 150 cycles is kept. Ultrathin three-dimensional carbon nanosheets are significant to fast electron transfer and Li+ diffusion contributing to excellent dynamic performance (710 mAh g−1 at 3 C).