How to Add Text or Banner on Header of Specific Pages or Products?

Topic summary

A user seeks guidance on adding text or banners to headers on specific Shopify pages/products while hiding header/footer elements from certain collections or products.

Two main approaches suggested:

  1. Theme Code Customization:

    • Requires editing theme files to conditionally display/hide header/footer sections
    • Insert HTML code for banners/text where needed
    • Risk of breaking theme if not experienced with code
  2. Shopify Apps (easier but may cost):

    • Use drag-and-drop interfaces to add banners/text
    • Set rules for which pages/products/collections display elements
    • Some apps allow conditional header/footer visibility

Practical solution provided:

  • Use sections available in collection templates
  • Connect dynamic sources to populate values automatically
  • Create metafields at collection level and assign data to collections
  • Screenshots and a YouTube tutorial link shared demonstrating metafield creation and value assignment

Multiple respondents recommend hiring a developer if unfamiliar with theme code to avoid potential issues. The discussion remains open with technical implementation details being clarified.

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

How to Add Text or Banner on Header of Specific Pages or Products, Header and Footer are Hidden from Specific Pages, Products or Collection?

Hello @fawadzia

It is possible to show site elements for some specific pages and can be dynamic for you so you can adjust in future. But it will need code alter, so if you are not good with code I would recommend you to seek help of a developer to help setup the same at reasonable cost.

let me know if you need one.

Thanks

Hi @fawadzia ,
This is Theodore from PageFly - Shopify Page Builder App.

There are two ways to add text/banners and hide headers/footers on specific Shopify pages/products:

  1. Theme Customization (code needed):

    • Edit theme code to hide header/footer sections conditionally (using code).
    • Insert HTML code for your text/banner where you want it.
  2. Shopify Apps (easier but might have costs):

    • Drag-and-drop interface to add text/banners.
    • Set rules for where they appear (specific pages/products/collections).
    • Some apps allow hiding headers/footers conditionally.

Best regards,
Theodore | PageFly

Hi, Could you please let me know what code and where I have to put in the theme?

It needs to be coded in the theme using theme format. Will you be able to
manage it? If you are not an expert then it can break your theme.

Hi @fawadzia ,

You can use any section available at collection template. please refer the below screenshot.

Now use connect dynamic source to provide the value dynamically.

To use dynamic source you have to create metafield variables at collection level and assign the data in collection.

How to create metafield and assign values into it please refer the below video.