Overview
Templates control what's rendered on each type of page in a theme.
Each page type in an online store has an associated template type. You can use the template to add functionality that makes sense for the page type. For example, you can add additional product recommendations to a product template.
Location
Template files are located in the templates
directory of the theme:
└── theme
├── layout
├── templates
| ├── 404.liquid
| ├── article.liquid
| ...
...
Subtypes
You can use Liquid file type in your theme. This template file type can be used to build multiple template types, each of which represents a type of content in a merchant's online store.
File type
The template type support only the Liquid file type.
Type | Description |
---|---|
Liquid | Liquid templates are Liquid markup files, with the .liquid file extension. |
Template types
Each available template type represents a type of content in a merchant's online store. No template types are required. However, you must have a matching template for any page type that you want to render. For example, to render a product page, you need at least one template of type product
.
You can use the following template types in your theme. To learn more about each template type, click on the template name.
Type | Description |
---|---|
404 | Renders page content that is shown to customers if they enter an invalid URL for the store. |
article | Renders the article page, which contains the full content of the article. This template is used for items like individual posts in a blog. |
blog | Renders the blog page, which lists all articles within a blog. |
cart | Renders the /cart page, which provides an overview of the contents of a customer’s cart. |
collection | Renders the collection page, which lists all products within a collection. |
customers/addresses | Renders the customer addresses page, which allows customers to view and manage their current addresses, as well as add new ones. |
customers/login | Renders the customer login page, which hosts the form for logging into a customer account. |
customers/order | Renders the customer order page, which displays the details of a customer’s past orders. |
customers/register | Renders the customer register page, which hosts the form for customer account creation. |
customers/reset_password | Renders the password reset page, which hosts the form to reset the password for a customer account. |
customers/reset_success | Renders the password reset success page. |
index | Renders the home page of the store, located at the root URL (/ ). |
order | Renders the customer order detail page, which displays the details of a customer’s past order. |
order_verify | Renders the order verify page, which can look up an order by email or phone. |
page | Renders the shop’s pages, such as About us and Contact us. |
password | Renders the /password page, which is a landing page shown when you add password protection to your online store. This page includes a message that is editable by merchants and the password form for customers to gain access to the store. |
product | Renders the product page, which contains a product's media and content, as well as a form for customers to select a variant and add it to the cart. |
search | Renders the /search page, which displays the results of a storefront search. |
Updated over 1 year ago