Troubleshooting Template Tests
Running into issues with a template test? This guide covers the most common problems and how to fix them.
I accidentally edited my original template
If you make changes to your A (original) template instead of your B (variant), those changes go live immediately for all visitors, including those not in your test.
How this happens
The Shopify Theme Editor looks the same whether you're editing your original or your variant. It can be easy to accidentally switch to the wrong template without realizing it.
How to prevent it
Before making any edits, check the template name at the top of the Theme Editor. Your variant template will have a different name from your original. Confirm you're editing the variant before making changes.

How to fix it
If you've already made changes to your original:
Undo immediately if you're still in the Theme Editor. Use Ctrl+Z (Windows) or Cmd+Z (Mac) to revert your changes, then click Save.
If you've already saved and closed, you'll need to manually revert the changes. Open your original template in the Theme Editor and undo whatever you changed.
If you're not sure what changed, check your theme's version history in Shopify. Go to Online Store > Themes > ... (more actions) > View version history to see recent edits.
Edits to your original template affect your live store right away, whether or not a test is running. Always double-check which template you're editing.
My variant looks broken or unstyled
If your variant page is missing styles, has a broken layout, or looks different from what you expected, your theme likely has code that checks the template name using an exact match. This is the most common technical issue with template tests.
Why this happens
When Shoplift creates a variant, it duplicates your template with a slightly different filename. For example, product.liquid becomes product.sl-XXXXXXXX.liquid.
Some themes include code that checks the template name to load styles, scripts, or sections. Code like this:
liquid
This code loads styles only when the template name is exactly product. Your variant's template name is product.sl-XXXXXXXX, so the check fails and the styles don't load. The page appears broken or unstyled as a result.
What to look for
Common symptoms include:
Missing CSS (the page looks unstyled or uses default browser styling)
JavaScript features not working (sliders, tabs, accordions, product image galleries)
Sections that appear on your original but are missing from your variant
Navigation highlighting not working on variant pages
The wrong page layout being applied
How to fix it
This requires a small update to your theme code. If you're comfortable editing Liquid, you can make the change yourself. Otherwise, share this section with your developer.
The fix is to replace exact template name checks with contains, which checks whether a string appears anywhere in the template name instead of requiring an exact match:
liquid
This works because your variant's template name is product.sl-XXXXXXXX, which still contains the string product. The contains check passes for both your original and variant templates.
The same fix applies to any template type:
liquid
Where to look in your theme code
The conditional checks that cause this issue are usually in your theme's global files, not in the template itself. Search your theme files for template == or if template .
To search your theme code, go to Online Store > Themes > Edit code, then use the search bar to find template ==.
My variant changes are showing on my original pages too
If changes you made to your variant are also appearing on your original, this is usually the same theme code issue described in My variant looks broken or unstyled, just showing up differently.
In some cases, theme code applies logic based on the page type rather than the specific template. For example, a snippet that adds a banner to "all product pages" will affect both your original and variant because they're both product templates. The fix is the same: update your theme code to distinguish between templates using request.page_type, template.suffix, or Shopify objects.
If the changes are coming from a section that's shared across templates (like a global header or footer), those sections aren't part of the template test. Changes to shared sections affect your entire store. To test changes to shared sections, use a theme test instead.
Still need help? Contact Shoplift support.
Last updated
Was this helpful?