Unique Header for Home Page

Topic summary

A user building a Shopify theme (Maker from Troop Themes) wants different header configurations for different pages:

Home page header group should include:

  • Header
  • Announcement bar
  • Slideshow
  • Split announcements

All other pages should only show:

  • Header
  • Announcement bar

The challenge was that the slideshow section needed to be in the header group (not the template group) to position it above split announcements.

Solution provided:
Edit the theme.liquid file by locating the </body> tag and adding conditional Liquid code to hide the slideshow on non-homepage templates:

{% unless template.name == 'index' %}
{% endunless %}

The solution successfully resolved the issue, allowing the slideshow to display only on the homepage while maintaining the desired header structure across all pages.

Summarized with AI on November 6. AI used: claude-sonnet-4-5-20250929.

Hi!

I am in the process of building out a new theme, Maker from Troop Themes.

Through the theme editor, I have customised the header group to contain the following sections:

  1. header

  2. announcement bar

  3. slideshow

  4. split announcements

I would like the header group to display the above sections ONLY on the home page.

On all other pages, I would like the header group to contain these sections:

  1. header

  2. announcement bar

How would I go about doing this? I’ve looked at a bunch of threads and tried many many liquid and CSS code edits but none are resolving my specific question.

For context, I wouldn’t usually place the home page slideshow/banner section in the header group, but I want it to be positioned above the split announcements section & I cannot add split announcements to the template group (where individual page content sits)

Here is the preview link to the theme I am working on for reference: https://svo33bh6wnqbr8gu-66004811958.shopifypreview.com

Thank you for reading, hopefully someone can help me out :slightly_smiling_face:

(attached is a screenshot of the header group sections I want on home page, on all other pages only the first 2 seconds should show)

1 Like

Hi @louisesookee

Do you mean you dont want the slideshow to be visible on other page only on the homepage?

If it is check this one.

From your Shopify admin dashboard, click on “Online Store” and then “Themes”

Find the theme that you want to edit and click on “Actions” and then “Edit code”.

In the “theme. Liquid” file. Find the tag and paste the code below before the tag.

{% unless template.name == 'index' %}

{% endunless %}

And Save.

Please don’t forget to Like and Mark Solution to the post that helped you. Thanks!

Thank you! This is exactly what I was after and has worked perfectly :slightly_smiling_face: