JSON-LD
JSON-LD (JavaScript Object Notation for Linked Data) is the recommended format for implementing structured data on your online store. It is used to provide Google with accurate product information, which can result in rich snippets in search results.
What is JSON-LD?
JSON-LD is a format for describing structured data in a script tag within your HTML. It’s used to convey precise information about your content to search engines—such as products, prices, reviews, organization details, FAQs, and more—in a machine-readable format based on the schema.org vocabulary.
JSON-LD is Google’s preferred format for structured data because it is separate from the HTML code and easy to implement and maintain.
JSON-LD vs. Other Formats
- JSON-LD: Implemented as a standard script element with the type application/ld+json. Separate from HTML. Easy to generate dynamically from the backend. Google’s recommendation.
- Microdata: Attributes are added directly to HTML elements. Closely tied to the HTML structure; harder to maintain.
- RDFa: Similar to Microdata, but with a different set of attribute names. Rarely used in e-commerce.
JSON-LD example for a product
A simplified example of Product markup:
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Nike Air Max 90",
"image": "https://dinshop.dk/img/nike-air-max-90.jpg",
"description": "Classic running shoe in black",
"sku": "NAM90-BLK-42",
"gtin13": "5060355123456",
"brand": { "@type": "Brand", "name": "Nike" },
"offers": {
"@type": "Offer",
"price": "899.00",
"priceCurrency": "DKK",
"availability": "https://schema.org/InStock"
}
}
Relevant schema types for online stores
- Product + Offer: Product information including price, availability, and condition. The most important information for an online store.
- AggregateRating + Review: Customer reviews and aggregate ratings. Displays star ratings in search results.
- BreadcrumbList: Breadcrumb navigation for better SERP display.
- Organization: Company information, logo, and contact details.
- FAQPage: Frequently asked questions with answers; can be displayed directly in the SERP.
- Article: For blog posts and guides, including author, date, and image.
JSON-LD in Shoporama
Shoporama’s official themes (Delaware, DelawareDK, and Montana) automatically generate JSON-LD for product pages with:
- Product schema with name, description, URL, images, SKU, GTIN, MPN, and brand
- Offer with price, currency, availability, and price validity period
- AggregateRating with average rating and number of reviews
- Review with individual customer reviews, author, and rating
- Open Graph tags that supplement the structured data for social media
On an official theme, this happens automatically. If you’re using an older or custom-developed theme, your theme developer can add JSON-LD based on the examples above.
Test and validate
- Google Rich Results Test: Check whether Google can read and understand your JSON-LD data and potentially display rich results.
- Schema Markup Validator: Verify that the JSON-LD is syntactically correct.
- Google Search Console: See which rich results Google has detected for your site and any errors.
How to Use Shoporama
Guides that demonstrate the concept in practice
Implement structured data (Schema.org) in your Shoporama theme
Complete guide to JSON-LD structured data in a Shoporama theme. Smarty examples for Product, Store, BreadcrumbList...
SEO in Shoporama
Complete guide to the SEO features in Shoporama - from meta tags and sitemap to Google Shopping and AI Assistant.
We know online marketing in Shoporama
We've been working with online marketing ourselves for decades. As the only shop system in the country, we have spoken multiple times at conferences such as Marketingcamp, SEOday, Shopcamp, Digital Marketing, E-commerce Manager, Ecommerce Day, Web Analytics Wednesday and many more.