Change the number of products shown on collection pages

You can change the number of products that are shown on your collection pages, either by making changes to your theme settings in the theme editor, or by editing your theme's code. You can show any number of products you like, as long as you don't exceed Shopify's limit of 50 products per page.

Check your theme settings

  1. Before making changes to your theme code, go to the theme editor.
  2. From the drop-down menu at the top of the page, or from the Templates menu on mobile, select Collection pages.
  3. Click Collection pages or Collection.
  4. If your theme has settings available to change the number of products that display on collection pages, then adjust the settings to fit your needs.
  5. Click Save.

If your theme doesn't have settings to change the number of products that display per page, or if the settings exist but are too limited for the changes that you want to make, then follow the next steps to edit your theme's code.

Update the collection-template.liquid file

Desktop
  1. From your Shopify admin, go to Online Store > Themes.
  2. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  3. In the Sections directory, click collection-template.liquid.
  4. In the code editor, find the following code:
 {% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.
iPhone
  1. From the Shopify app, tap the button.
  2. In the Sales channels section, tap Online Store.
  3. Tap Manage themes.
  4. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  5. In the Sections directory, click collection-template.liquid.
  6. In the code editor, find the following code:
 {% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.
Android
  1. From the Shopify app, tap the button.
  2. In the Sales channels section, tap Online Store.
  3. Tap Manage themes.
  4. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  5. In the Sections directory, click collection-template.liquid.
  6. In the code editor, find the following code:
 {% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.

In the above example, the default number of products per page is 9. This number varies theme to theme. You can change this number to be the number of products that you want to show on your collection pages. The maximum number of products per page is 50.

Some themes use a variable called limit instead of a number to determine how many products will be shown per page. If your theme uses a limit variable, the code will look like this:

 {% paginate collection.products by limit %}

If your theme uses a limit variable, you will need to replace limit with a number. As above, this is the number of products that will show on each collection page, and the number must not be more than 50. Note that replacing the limit variable with a number will remove the ability to make changes to the collection pages pagination settings in the theme editor. We recommend that you not edit your theme code unless you are unable to achieve the desired number of products per page in the theme editor.


Update the collection.liquid file

Desktop
  1. From your Shopify admin, go to Online Store > Themes.
  2. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  3. In the Templates directory, click collection.liquid.
  4. In the code editor, find the following code:
{% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.
iPhone
  1. From the Shopify app, tap the button.
  2. In the Sales channels section, tap Online Store.
  3. Tap Manage themes.
  4. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  5. In the Templates directory, click collection.liquid.
  6. In the code editor, find the following code:
{% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.
Android
  1. From the Shopify app, tap the button.
  2. In the Sales channels section, tap Online Store.
  3. Tap Manage themes.
  4. Find the theme you want to edit, click the button to open the actions menu, and then click Edit code.
  5. In the Templates directory, click collection.liquid.
  6. In the code editor, find the following code:
{% paginate collection.products by 9 %}
  1. Change the number in the code to the number of products that you'd like to to display on your collection page, and then click Save.

In the above example, the default number of products per page is 9. This number varies theme to theme. You can change this number to be the number of products that you want to show on your collection pages. The maximum number of products per page is 50.

Some themes use a variable called limit instead of a number to determine how many products will be shown per page. If your theme uses a limit variable, the code will look like this:

{% paginate collection.products by limit %}

If your theme uses a limit variable, you will need to replace limit with a number. As above, this is the number of products that will show on each collection page, and the number must not be more than 50. Note that replacing the limit variable with a number will remove the ability to make changes to the collection pages pagination settings from the theme editor. We recommend that you not edit your theme code unless you are unable to achieve the desired number of products per page from the theme editor.

Can’t find the answers you’re looking for? We’re here to help.