How to Render a Template in another Template

Hi everyone,

I’m trying to simplify how headers and footers are handled on specific pages like Cart, Checkout, and Order Confirmation.

I have explained below and recorded a short video if you don’t want to read the whole text. How to inject one template into another template | Cap Recording

What I want

On these pages, I don’t want to render the global Header and Footer templates.
Instead, I want a much simpler header and footer layout.

The current approach (and the problem)

Yes, I know I can:

  • Create a second Header template
  • Create a second Footer template
  • Apply display conditions to Cart, Checkout, etc.

But this feels repetitive and hard to maintain.

If I add another page later that needs the same simplified layout, I’ll have to:

  • Edit the Header template conditions
  • Edit the Footer template conditions

That means updating multiple places every time.

What I’m trying to achieve

I want to create a Single template (for example: “Headerless Template”) that:

  • Does NOT render the global Header or Footer
  • Controls its own header, footer, and content area
  • Wraps the Cart and Checkout templates inside it

So the structure would be something like:

/cart
→ uses “Headerless Template”
→ which renders the Cart template inside it

In other words:

Headerless Template
→ includes Cart / Checkout templates
→ without loading the global header & footer

The issue

This doesn’t seem to work when Cart and Checkout have their own separate templates.

Has anyone successfully structured it this way?
Is there a clean way to make Cart/Checkout templates inherit from a custom Single template instead of the global layout?

Thanks,