How to Find the robots.txt File

Understanding and Editing the Robots.txt File for Shopify and WooCommerce

The robots.txt file is a crucial component for controlling how search engines crawl and index your website. This file can help you manage which parts of your site should be accessible to search engine bots and which should not.


Shopify automatically generates a robots.txt file for your store. However, as of mid-2021, Shopify allows you to edit this file to better suit your SEO needs.

  1. Go to your Shopify admin panel.
  2. Navigate to Online Store > Actions > Edit Code.
  3. In the Templates section, click on robots.txt.liquid.
  4. Edit the file as needed. For example, to disallow all bots from accessing the /admin directory, you would add:
    User-agent: *
    Disallow: /admin/
  5. Click Save to apply your changes.

WooCommerce (WordPress)

For WooCommerce stores on WordPress, you can manually create or edit the robots.txt file.

  1. Access your WordPress dashboard.
  2. Navigate to SEO (if using a plugin like Yoast SEO) > Tools > File Editor.
  3. If you don’t have a robots.txt file, you can create one. If you do, you can edit it directly.
  4. To disallow all bots from accessing the /wp-admin directory, add:
    User-agent: *
    Disallow: /wp-admin/
  5. Click Save Changes to update the file.

By properly configuring your robots.txt file, you can ensure that search engines index the most important parts of your eCommerce site while avoiding less relevant sections.