Automatically Add Product to Cart

Highlighted
New Member
5 0 0

Hi all

 

I have a product that comes with a free gift - I want to automatically add it to the cart when someone makes a purchase to keep track of the inventory SKU.


How can I do this without an app? I'm not much of a coder but I understand it so I can add any code myself

0 Likes
Highlighted
Tourist
14 0 2

Hello!
You could use the Ajax Cart API to automatically add that product into the cart, either on cart page load or in a function binded to the checkout button.

International team available for Store creation and Theme/App development!
0 Likes
Highlighted
New Member
5 0 0

Any hints for the coding on how to do that? I have no idea where I would put that into the code.

0 Likes