How to add “Add to cart” button on Shopify collection pages for each product

Sell Online With Shopify
Trusted by millions of businesses worldwide
Sign up for a free trial and enjoy 3 months of Shopify for $1/month on select plans.

You can create an “Add to cart” button that features a single product that includes one or all of the product’s variants on your collection pages. This will allow your clients to easily and effortlessly add products to cart without opening the product page.

Please follow below steps to add “Add to cart” button on Shopify collection pages for each product.

  1. From your Shopify admin, to to Online Store > Theme.
  2. Find the theme you want to edit and then click Action > Edit code.
  3. In the online code editor of collection page find to the loop {% for product in collection.products %} add the below code.
  4. Hit Save, and you’re done!

Happy coding!

Looking for Shopify Experts?

Hura Apps can help you take your store to the next level

Our team of experienced designers and developers can help you create a beautiful, high-converting Shopify store that will drive sales and increase customer satisfaction. From custom design to app development and optimization, we have the skills and expertise to help you achieve your eCommerce goals.

Get in touch

You may also like...

4 Responses

  1. Prince Bhagat says:

    Great guys, this code helped me a lot. But i have a problem, when add to cart is pressed it takes the customer to the cart page. Is it possible to stay on the collection page after clicking add to cart ?

  2. Ashish says:

    Can someone please guide me to add price to the Drop down in this along with the Variants.

Leave a Reply

Your email address will not be published. Required fields are marked *