Hide pricing from search engine listing while still allowing Google to index the page

Hide pricing from search engine listing while still allowing Google to index the page

BYGroup
Tourist
5 0 1

We are building a B2B website, and our pricing is already hidden throughout our site. 

 

However, it still appears in our search engine listing. Most other recommendations are to disable crawling for the pages with pricing. This is not an acceptable solution. 

 

How can we hide our pricing from our search engine listings, and still allow our pages to be indexed by Google?

 

Thank you. 

 

Screenshot 2024-08-06 144930.png

Replies 7 (7)

Edgywebsites
Shopify Partner
24 2 35

Hi, 
To achieve this, you'll have to remove all the pricing data form the product schema and for the price within the product page, only show it for logged in users. 

If our response solved your query, please like and accept it as the solution.

Edgy Websites · All things Shopify
Contact us for Expert Shopify Support

PaulMartin
Shopify Partner
443 52 106

The price displayed in search engine listings is set within a script tag found in the product page's code. For example:

 

<script type="application/ld+json">
      {
        "@context": "http://schema.org/",
        "@type": "Product",
        "name": "Blue Snowboard",
        "url": "https:\/\/martin-dumpstore.myshopify.com\/products\/blue-snowboard",
        "image": [
            "https:\/\/martin-dumpstore.myshopify.com\/cdn\/shop\/files\/stem.png?v=1721550190\u0026width=1920"
          ],
        "description": "",
        
        "brand": {
          "@type": "Brand",
          "name": "martin-dumpstore"
        },
        "offers": [{
              "@type" : "Offer","availability" : "http://schema.org/InStock",
              "price" : 100.0,
              "priceCurrency" : "PHP",
              "url" : "https:\/\/martin-dumpstore.myshopify.com\/products\/blue-snowboard?variant=48879522382128"
            }
]
      }
    </script>

 

This script tag determines what will be displayed in search engine listings. To remove the price, simply delete the "price" from within the script tag.

Contact here for WhatsApp | Email
$20 start rate for theme fix & customization
Don't forget to like and mark as solution
BYGroup
Tourist
5 0 1

Thank you.  What if it needs to be done for every SKU?  Is there a way to do it across the entire store? 

Edgywebsites
Shopify Partner
24 2 35

Yes, the JSON scheme is most likely being generated using a template. You'll need to update that template and it'll apply for all the products given that it's the default template for the products. 

If our response solved your query, please like and accept it as the solution.

Edgy Websites · All things Shopify
Contact us for Expert Shopify Support
BYGroup
Tourist
5 0 1

Thank you!  Where do we locate the JSON scheme to edit it?

BYGroup
Tourist
5 0 1

Would this be within product.json? Can I utilize 

{% comment %} {% endcomment %} to comment out any references to price, or do they need to be deleted? 

Edgywebsites
Shopify Partner
24 2 35

It could be within a section of the product page. If your product page template is a JSON template then you won't be find it there as it's simply a template specifying the sections that make up your product page. I'd recommend you seek professional help if you're familiar with aforementioned processes. 

If our response solved your query, please like and accept it as the solution.

Edgy Websites · All things Shopify
Contact us for Expert Shopify Support