Eight Themes Support Documentation

How to Create Custom Page Templates

What is a custom Page Template?
Custom page templates allow you to create and utilise different page templates, with different content, across groups of products, collections, blogs, or pages.  They're a great way to customise your store, and enhance your customer experience!
By default - your theme will use the same template for all your groups of pages (so, the same template for all product pages, the same template for all collection pages etc).  This is known as the default template, and any changes you make to this will reflect across all pages of that type - so, if you add a section to your default product page template, this section will appear on all of your default product page templates.  
Using custom page templates, you can add different sections and create different layouts for specific pages on your store - rather than using the default template, which would give each type of of page on your store the same sections and layout.  You can assign a different, custom Page Template to as many pages of your store as you'd like.  
How do I create a custom Page Template for a Collection, Product, Page or Blog?
When adding a section to a template, for example, an 'Image with text' section to a collection page, this section will display on all collections as they share the same, default template.  When viewing a different collection page, using this same default template, the only differences will be the actual content of the collection (the products displayed, available within the selected collection).  
The way to get around this is to create a custom template and assign to a collection, product, page or blog. This will allow you to now add a section independently to the new custom template only.
This applies to all available page templates, and the process to create a Page Template is the same, regardless of the type of template you're creating.  For this example, we'll be creating a custom Page Template for a Collection page, but you can apply the same principle to any type of template. 
Step 1: Create the template
1 - Open the template selector, and select the 'Collection' option, and then click ‘create template’ (Remember - if you're creating a custom template for a different type of page, select this instead):
2 -  Name the new, custom page template - we recommend using a unique name to make this easily identifiable:
Influence - testing store ~ Customize Copy of influencedeploydevelopment ~ Shopify 2022-05-11 at 1.48.23 pm
Please note - the template will be 'based on' the default template for the page type you've selected - in this case, we're creating a custom collection page template, 'based on' (so, featuring the same functionality) as the default collection template. 
3 - Assign the custom template to the specific collection - navigate to Collections, select the new template and save.  (Please note: the theme you are customising will need to be live in order for the template to show as available for selection):
4 -  Navigate to your Collection section in your theme editor, and select your new custom template - you can now add sections independently of your other Collections Page Templates! 
You'll now be able to create different templates for your pages - allowing you much greater flexibility and creativity with your store!  You can create as many templates as you'd like - and assign them to multiple pages, or keep them standalone. 

How do I delete a template?
To delete a template, you'll need to use the code editor.

1.  From your Shopify admin, go to Online Store > Themes.
2.  Find the theme you want to delete a template from, and then click Actions > Edit code.
3.  In the code editor, find the templates' folder. Click on the name of the template you want to delete, and then click Delete file. If you have any resources assigned to that template, they will be displayed with the default template until you assign a different one.
How do I change my template's name?
You can't change a template's name after it has been created. If you want a template with a new name, then you can create a new template based on the old one, and give it the new name, before deleting the original template.


Please click here to see Shopify guide on custom templates for more information


Was this article helpful?