How to implement markups on shopify?

by , in category: SEO , 9 months ago

How to implement markups on shopify?

Facebook Twitter LinkedIn Telegram Whatsapp Pocket

1 answer

by percy_bauch , 9 months ago 

To implement markups on Shopify, you can follow these steps:

  1. Log in to your Shopify account and navigate to the "Online Store" section of your admin dashboard.
  2. Under "Online Store," choose "Themes."
  3. Find the theme you want to edit and click on the "Actions" dropdown. Then select "Edit code."
  4. In the theme editor, locate the "Templates" folder and open the "product.liquid" file. This is where you will add the markup for individual product pages. If you want to add markups for other pages, like the homepage or collection pages, you'll need to locate and edit their respective template files.
  5. Inside the "product.liquid" file, identify the relevant product information such as product name, description, price, SKU, etc. and wrap that information with the appropriate markup tags. For example, you can use the "Product" schema markup by adding the following code:
<script type="application/ld+json">
  "@context": "",
  "@type": "Product",
  "name": "{{ product.title }}",
  "description": "{{ product.description | strip_html | escape }}",
  "sku": "{{ product.sku }}",
  "offers": {
    "@type": "Offer",
    "price": "{{ product.price }}",
    "priceCurrency": "{{ shop.currency }}"
  "image": "{{ product.featured_image | product_img_url: 'large' }}"

Make sure to replace the liquid variables such as {{ product.title }} and {{ product.description }} with the corresponding liquid tags for retrieving the actual product information.

  1. Save the changes and test your website's product pages with Google's Structured Data Testing Tool or any other similar tool to ensure the markup is working correctly and there are no errors.
  2. Repeat the above steps for other template files if you want to add markups to other areas of your Shopify store.

It's important to note that the specific markup you use will depend on the type of content or page you are trying to mark up. Refer to the documentation to find the appropriate markup for each type of content.

Remember to backup your theme files before making any changes, and in case you encounter any issues, you can always revert to the original version.