How to Add Load More Button on Collection Page Shopify

If you want to add load more button on Shopify collection page instead of default pagination button, then we are going to explain you step by step process.

load more button shopify

Load more button enables you to show more products on collection page in shopify website without going to next page.

Check how to Create App and Getting Started With Shopify API in PHP

Steps to Create Load more button on Shopify:

Step 1: Add HTML code:

Open the collection-template.liquid file under section and look for ‘paginate.pages > 1’ condition code.

Like this: (% if paginate.pages > 1 %)

Now add below HTML code after this condition.

Step 2: Upload Loader gif image:

To show loading image, download any loader gif type image from google and upload in assets via ‘Add new assets’.

Make sure loader image name should be ‘loader.gif’, becuase we have mentioned this name in above HTML code.

Step 3: Add CSS code:

Now open ‘theme.scss.liquid’ file under Assests directory and add below css code at the end of file.

Now you will the pagination section has been hidden and Load More button will show on the Shopify collection page.

Step 4: Add Load More Javascript Code:

Open ‘theme.js’ file and add this javascript code here.

See, its quite easy to add load more button on shopify collection page.

Recommended Posts For You

About Harish

I am professional web developer and blogger. Use this blog to share own api and other web development experience with you. I do accept paid work. Write to me at - [email protected]

View all posts by Harish