Troubleshooting

If you are experiencing issues with your theme editor, then check if your issue appears below.

Common issues

Issue: Failed to load the page

Page is redirecting to an unsupported URL

If your storefront includes code that redirects users to URLs that are not connected to your shop, then verify that the redirect has been disabled when you visit the theme editor.

For example, this type of redirect might be added to a storefront to direct buyers to different Shopify stores depending on their location. This type of redirect code could exist in either your theme or an app that you installed.

To ensure your redirect doesn't interfere with the editor experience, use a reference to thewindow.Shopify.designModevariable in JavaScript to disable the redirect when you visit the theme editor. This variable is set totruewhen the storefront is loaded in the editor, andfalsewhen it isn't.

Page failed to load due to an error

A page can fail to load in the theme editor for many reasons. Common issues include the following:

  • network connection issues
  • invalid Liquid code in your theme

If you have verified that these issues are not causing the error, then try visiting your online store by navigating toTheme actions>Preview themein the theme editor. If the page fails to load, then you cancontact Shopify supportfor help with your storefront.

HTML error found

When making changes to your theme settings in thetheme editor, you might see an 'HTML error found' warning message in the editor:

HTML error banner

This error message appears when a syntax error is found in your theme code. To resolve the problem, you can examine the code in the Liquid file that is referenced in the error message. In the example above, this would be theslideshow.liquid.

Finding the problem in your theme code

  1. Click the.liquidsection file that is linked to in the error message. This will take you to theEdit HTML/CSS page, and the file will open in the code editor.
  2. Look through the code in the file and try to find invalid HTML or Liquid. The code editor will show potential syntax errors in red. Common problems include the following:
    • Extra closing HTML tags, for example, a closing
without an opening
  • Extra unclosed HTML tags, for example, an opening
    without a closing
  • Malformed HTML tags, for example,
    without a>
  • Malformed Liquid code
  • Broken HTML in an included theme snippet file
  • After you've found the problem, correct the code in your theme file.
  • ClickSave.
  • ClickCustomizeto return to the theme editor, and confirm that the error message is gone.
  • Other solutions

    If you are unable to resolve the problem by following the previous steps, then consider the following options:

    Ready to start selling with Shopify?

    Try it free