This was something that was keeping me up at night.

Metaphorically speaking. The only thing that can keep me up at night is my cat when he wants to eat.

The Issue: H2 Tag in Shopify Blog Post Title (Debutify Theme)

The issue was the following: the blog post title of one of my ecommerce stores, luciditydreammask.com, was being flagged as H2 instead of H1.

For those who are not familiar with Search Engine Optimization (SEO), the H1 tag is one of the most important on-page elements used by Google to rank pages.

I am pretty sure search engines nowadays can figure out what the title of a page is but, technically speaking, not having an h1 tag would be the equivalent of having a page with no title.

The result? Google would not immediately know what the page is about.

The Search for a Solution

I went through the usual Shopify community threads about missing h1 tags.

The most recommended solutions were to edit files such as article-template.liquid (or similar) from the Sections folder.

Unfortunately, none of these solutions worked for me.

I also tried to look at files such as hero.liquid, because the section the article title was in was the so-called ‘hero section’ of the page.

None of these worked.

I then decided to painfully go one file at the time, starting with the Templates folder and down to the Snippets one, until I finally found the correct file to edit: the article-image.liquid one!

The Solution: Edit article-image.liquid file

This is the step-by-step solution I used to solve the issue:

1. From the Shopify admin, click on Online Store. This will default to Themes

2. Click on the three dots (…) next to the Customize button

3. Select Edit Code from the dropdown menu

4. In the next screen, scroll down to Snippets and select article-image.liquid

5. Finally, replace both HTML <h2> and </h2> tags with <h1> and </h1>.

I hope you will find it helpful. Please let me know in the comments and of course feel free to share the solution!

Categorized in:

Tagged in:

, , ,