A template test serves a different page layout to each group, for one kind of page: product, collection, page, blog, article. It is the right answer when the question is genuinely about arrangement — does this product page work better with the reviews above the fold, does the collection need filters at the top — and the wrong answer when it is about wording, which a content test settles without a navigation.
Compared with a theme test it is narrower and therefore faster to conclude: you are changing one page type rather than every page, so the difference you are measuring is the difference you made.
Build the template first
In Shopify, open the theme editor and duplicate an existing template. Shopify names the copy something like product.myversion.json. Lay it out, save it, and it becomes available here.
Two requirements that are easy to miss:
- Every template must live in your live theme. This test does not switch themes; it asks your published theme to render a different template. One built in an unpublished theme is invisible to it.
- The control must be the template the page already resolves to. A visitor only enters the test if they land on a page whose default template is the control’s. That is what makes the comparison fair.
If you built the template a moment ago and it is not in the picker, the Modifications tab has a Refresh — themes and templates are re-read when the cached list is more than five minutes old, and manually when you ask.
Comparisons are rows, not per-group settings
This is the one tab in the app laid out across the groups rather than down them. A template comparison is a row: the origin template, then what each group renders in its place.
That is deliberate. Edited group by group you would be holding three separate lists in your head and keeping their order aligned by hand. As a row, the comparison reads as the single thing it is.
A test can hold several comparisons. A product comparison and a collection one, or two product comparisons for different products. Each carries the page type and the origin template it replaces, so the right one applies on the right page and the others stay out of the way.
What a shopper experiences
The loader lands on the page, decides the group, and replaces the URL with the alternate template. The page stays hidden across that hop, so there is no flash of the original — and the URL is tidied afterwards so the parameter is not something a shopper copies and shares.
The control does not navigate, which means the variant arms pay a navigation the control does not. It is small, and it is the honest cost of client-side template switching on a platform that serves storefront HTML from a CDN.
What to watch
- Check both templates on a phone. A layout that works at desktop widths and collapses on mobile will lose for reasons that have nothing to do with the idea you were testing.
- Run Check setup on the Preview tab. It loads the page with each template named and confirms the template is real, rather than your theme quietly falling back to the default.
- Do not run two navigating tests on the same pages. Theme, template and redirect tests all move the visitor. Two on overlapping URLs cannot both act, so the app refuses the combination rather than letting one quietly win.
- Content tests under a template test are a warning. Not a refusal — it is a legitimate pair — but selectors written against one layout may match nothing in the other, and that half of the traffic then reads as “no difference” rather than as a failure.
When it wins
Make the winning template the default in your theme, then end the test. Until you do, every visitor is being redirected on every page view for a layout you have already decided on.