The industrialization of lithium-sulfur (Li-S) batteries faces challenges due to the shuttling effect of lithium polysulfides (LiPSs) and the growth of lithium dendrites. To address these issues, a simple and scalable method is proposed to synthesize 2D membranes comprising a single layer of cubic graphitic cages encased with few-layer, curved MoS2. The distinctive 2D architecture is achieved by confining the epitaxial growth of MoS2 within the open cages of a 2D-ordered mesoporous graphitic framework (MGF), resulting in MoS2@MGF heterostructures with abundant sulfur vacancies. The experimental and theoretical studies establish that these MoS2@MGF membranes can act as a multifunctional interlayer in Li-S batteries to boost their comprehensive performance. The inclusion of the MoS2@MGF interlayer facilitates the trapping and conversion kinetics of LiPSs, preventing their shuttling effect, while simultaneously promoting uniform lithium deposition to inhibit dendrite growth. As a result, Li-S batteries with the MoS2@MGF interlayer exhibit high electrochemical performance even under high sulfur loading and lean electrolyte conditions. This work highlights the potential of designing advanced MoS2-encased heterostructures as interlayers, offering a viable solution to the current limitations plaguing Li-S batteries.