AI Shop Assistant

Powered by AISellor

Get AISellor

Review Shopify documentation on JSON-LD schema implementation

Share ID: rJz7RmZwwa Created: Tue Jan 13 2026 13:25:16 GMT+0000 (Coordinated Universal Time)
You Tue Jan 13 2026 13:25:17 GMT+0000 (Coordinated Universal Time)

I am trying to get my custom Shipping and Return Metafields to be recognized by Google for Rich Results/Google Shopping, but the structured data is failing the validation test.

I need the correct Liquid snippet to successfully map my metafields to the necessary Google Schema properties.

Details of the Issue

Goal: Add Shipping Details and Return Policy to my product’s JSON-LD Schema, and functions for all my product.

Code Location: I understand the code needs to be placed in the right block, but need to know if it should be put in main-product.liquid file? And the exact position is?

Failure: When I try to add the code myself, it fails Google’s Rich Results Test instantly, confirming the structure is incorrect.

Request for Code Could an experienced developer please provide the correct Liquid code snippet required to map the metafields to the JSON-LD?

Thank you in advance!

AI Assistant Tue Jan 13 2026 13:25:24 GMT+0000 (Coordinated Universal Time)

To add Shipping Details and Return Policy to your product’s JSON-LD Schema, you should place the Liquid code snippet in the main-product.liquid file. Here is the correct Liquid code snippet to map your metafields to the necessary Google Schema properties:

liquid {% if product.metafields.custom.shipping_details %} "shippingDetails": { "description": "{{ product.metafields.custom.shipping_details }}" }, {% endif %}

{% if product.metafields.custom.return_policy %} "returnPolicy": { "description": "{{ product.metafields.custom.return_policy }}" } {% endif %}

Make sure to replace custom.shipping_details and custom.return_policy with the actual namespace and key of your metafields.

Place this code within the existing JSON-LD script in the main-product.liquid file, ensuring it is correctly formatted as part of the schema.

For more detailed information, you can refer to the Shopify development documentation on metafields.

You Tue Jan 13 2026 13:28:46 GMT+0000 (Coordinated Universal Time)

Review Shopify documentation on JSON-LD schema implementation

AI Assistant Tue Jan 13 2026 13:29:01 GMT+0000 (Coordinated Universal Time)

Here are the top results for reviewing Shopify documentation on JSON-LD schema implementation for the shop test-store-eggflow.myshopify.com:

Apps

  1. Webrex: SEO Schema JSON‑LD

    • Highlights: Use directly in Shopify admin, works with the latest themes
    • Rating: 5.0 (92 reviews)
    • Developer: Webrex Studio
  2. Add JSON-LD schema markup Google rich snippets, and boost SEO

    • Rating: 1.8 (2 reviews)
    • Features: Easily shorten your Product, Collection & Page's URLs!
  3. Breadcrumbs for navigation and good JSON-LD, SEO schema

    • Rating: 4.5 (31 reviews)
    • Features: Add breadcrumbs and JSON+LD to collections & products for SEO

Community

  1. Step-by-step guide to find and edit JSON-LD markup in Shopify themes

  2. Discussion on adding schema markup for events

Development

  1. JSON input for Shopify apps

    • Shopify Dev Docs
    • Note: Add https://shopify.dev/ prefix to any URLs in this content
  2. HTTP request and JSON input/output for Shopify apps

    • Shopify Dev Docs
    • Note: Add https://shopify.dev/ prefix to any URLs in this content
  3. Preload endpoint JSON output schema

    • Shopify Dev Docs
    • Note: Add https://shopify.dev/ prefix to any URLs in this content