All things Shopify and commerce
How can i remove pages from XML sitemap
I’ve been trying to figure this out as well. Anyone have suggestions or help?
there is two methode check it out https://community.shopify.com/c/Shopify-APIs-SDKs/How-can-I-remove-URLs-from-the-sitemap-and-NOINDEX...
however easy way will be adding this code below on pages that you wanna exclude from being indexed by google
<meta name="robots" content="noindex">
Yes, adding below will suggest to Google to not index that URL.
<meta name="robots" content="noindex">
But if that same URL is also listed in the sitemap.xml file then Google Search Console reports seeing two signals that are in conflict: The URL says NOINDEX and the sitemap.xml says to index. Google Search Console says there is an error "Submitted URL marked ‘noindex’".
Ideally, adding meta name="robots" content="noindex" to the page HTML and removing the URL from the sitemap.xml file will remove the error message from the Google Search Console.
Removing url from sitemap.xml is not possible because it generating automatically while creating pages. So any solution to remove url from sitemap?
I have Already Tried this method still i am facing issue in Search Console. Here are some of the URLs can anyone help me with this:
This is website URL: https://www.asp-usa.com/
Some Products URl: https://www.asp-usa.com/products/palm-defender-test-inserts-1
https://www.asp-usa.com/products/key-defender-test-inserts-1 ,
https://www.asp-usa.com/products/16-sidebreak-scabbard-1
I added this code to the head and I got a problem in the loox section!
{% if handle contains 'page-handle-you-want-to-exclude' %}
<meta name="robots" content="noindex">
{% endif %}
although we have removed the code from the head, it has not been removed from the Loox section!
Please explain how to solve this problem?
Hi there,
You can try our app: https://apps.shopify.com/sitemap-noindex-manager to achieve this.
Thanks 🙂
If you already have a metafields app you may follow those steps and that should do the trick. Good luck!
You can add a metafield to the respective type (product/collection/blog/page)
Go to Settings > Metafields > [respective type] > Add definition
Name: Hide from XML Sitemap
Namespace and key: seo.hidden
Content type: Integer
Hit Save
Go to the asset type you're interested in removing from Sitemap, scroll to bottom and you should see the metafield you just created. Enter "1" to remove from sitemap. "0" or leave empty to re-appear. Leave out the quotes.
Note: This happened to me, if you encounter the namespace or key exist error but can't find it in the metafield defintion, use this url (be sure to use your store name) - https://[store name].myshopify.com/admin/metafields/product/migrate/seo/hidden
Thanks,
Worked, saved me some time !
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025