Joined: Oct 2019
Posts: 9
Likes Received: 0
How to add Poducts schema code for shopify website ?
Joined: Mar 2018
Posts: 103
Likes Received: 6
Just add like any other site. Just check it once after you have added.
And if run into any problems its better that you consult to Shopify community for that.
Joined: Sep 2015
Posts: 673
Likes Received: 5
(10-19-2019, 07:50 AM)bsystems Wrote: Just add like any other site. Just check it once after you have added.
And if run into any problems its better that you consult to Shopify community for that.
The OP is asking on how to add products in schema code, not just add like any other site because you said nothing at all.
Joined: Mar 2018
Posts: 103
Likes Received: 6
(10-25-2019, 06:38 AM)steveposter Wrote: (10-19-2019, 07:50 AM)bsystems Wrote: Just add like any other site. Just check it once after you have added.
And if run into any problems its better that you consult to Shopify community for that.
The OP is asking on how to add products in schema code, not just add like any other site because you said nothing at all.
I didn't know that they are different. Then why didn't you answered the query?
Joined: Sep 2016
Posts: 415
Likes Received: 289
Why are you guys quarreling? OP has clearly bolted.
Joined: Nov 2021
Posts: 68
Likes Received: 3
Adding Product schema code to your Shopify website is a great way to help manage product inventory and keep track of sales. This code can be added to the themes or pages you want to include it on, and it will automatically update when new products are added, or changes are made to existing products.
To add Product schema code:
Open the Shopify admin area by visiting the Shopify website.
Click on Themes in the left-hand menu and select the theme you want to modify.
Locate Products in the right-hand menu and click on Add New underneath it.
In the newly opened window, enter a name for this product.
Joined: May 2022
Posts: 161
Likes Received: 16
login to the backend of your Shopify store and go-to the online store>Themes>Action>Edit Code.
Joined: May 2022
Posts: 154
Likes Received: 9
just make sure the code/scrip is error-free, warnings can be ignored.
Joined: May 2022
Posts: 154
Likes Received: 9
Added the code @OP?
Any queries/confusion?
Joined: Jun 2020
Posts: 54
Likes Received: 4
To add Product Schema code to your Shopify website, follow these steps:
Log in to your Shopify account and go to the "Online Store" section.
Click on "Themes" and then select "Actions" and "Edit Code" on the theme that you want to add the schema code to.
Open the "product-template.liquid" file.
Scroll down to the bottom of the file and locate the </body> tag.
Just before the </body> tag, paste the following code:
json
Copy code
<script type="application/ld+json">
{
"@context": "http://schema.org/",
"@type": "Product",
"name": "{{ product.title }}",
"image": "{{ product.featured_image | img_url: '600x600' }}",
"description": "{{ product.description | strip_html | escape }}",
"sku": "{{ product.sku }}",
"brand": {
"@type": "Brand",
"name": "{{ product.vendor }}"
},
"offers": {
"@type": "Offer",
"price": "{{ product.price }}",
"priceCurrency": "{{ shop.currency }}"
}
}
</script>
Save the changes and preview the product page to ensure that the schema code is displaying correctly.
Note: Make sure to replace the liquid variables in the code with the appropriate variable names used in your Shopify store. Also, note that this code only covers the basic product schema, and additional schema properties can be added as per your requirement.