How to Remove Default /collections/all and /products URLs from Search and Storefront?

I build a minimal custom site with just three core pages:

  • Home

  • About Us (custom-built)

  • Shop (custom-built, featuring a single product with a custom buy/add-to-cart interface)

I’m not using default collection or product templates. However, the default URLs like:

  • /collections/all

  • /products/my-product-name

are still accessible and are appearing in Google search results — even though I’ve already set up URL redirects from them to my custom /pages/shop via the Admin panel.

how to solve this issue ?

Hi @kiran_sagar ,

To fully prevent default Shopify URLs like /collections/all and /products/my-product-name from appearing in Google and redirect them properly, setting up URL redirects in the Admin panel alone isn’t always enough because those default URLs still exist on the server and can be crawled. To fix this, you should create a Shopify theme-level redirect by adding code in your theme.liquid or in the relevant template files that detects these default URLs and performs a 301 redirect to your custom /pages/shop. Alternatively, use Shopify’s robots.txt to disallow crawling of unwanted default paths and combine it with canonical tags on your custom pages pointing to /pages/shop to consolidate SEO signals and prevent indexing of default URLs. This combined approach ensures both users and search engines are properly directed and the default pages don’t appear in search results.

Thanks!

Hi @kiran_sagar ,

To resolve the issue, start by adding a tag in your product.liquid and collection.liquid files to prevent search engines from indexing those default pages. Next, customize your robots.txt.liquid file to include Disallow: /products/ and Disallow: /collections/, which tells crawlers not to access those URLs. Since Shopify’s built-in redirects are 302 by default, use an app or the API to create proper 301 redirects so SEO value is preserved. Then, go to Google Search Console and request removal of any unwanted URLs that are already indexed. Finally, make sure there are no internal links or sitemap references pointing to the default product or collection pages.

If my reply is helpful, kindly click like and mark it as an accepted solution.
Thanks!
Use our Big Bulk Discount app to boost your sales! :rocket: (https://apps.shopify.com/big-bulk-discount). Easy to set up and perfect for attracting more customers with bulk discounts. Try it now and watch your revenue grow!

Hi @kiran_sagar

Concerning the page redirects you set up before, I think you may need to pay more attention to the format whether you set them up properly and how Google works to know and index them, as some redirections you made before may not be recognized by Google correctly or properly, this is why you can still see the default URLs displaying in the search results.

Moreover, Google may not index pages with redirects if the redirected URL is considered of lower quality or importance than the target URL. When a website is restructured, pages may be redirected to new URLs. Google focuses on indexing the new, preferred URLs, not the older, redirected ones. This may be one of the cause codes as well, why Google did not display the redirects result in some ways.

I found an article from Search Console Help about how Google indexes pages, and you can make it as a reference meanwhile, maybe it can give you some ideas meanwhile. Thank you!

can you break this down further into an actual step by step because im ha ving the same problem, and no clue how to fix this!