On this page

In most cases, we recommend to use the available Buy Box blocks which have "Cart" and "Checkout" button destination options built-in. Using these blocks, you can easily set them up so that when a page visitor clicks on them, it will add the product to the Cart or Checkout on your store. 

If you're using a non-Buy Box block, then you can set the "button destination" to URL and use a Cart or Checkout permalink to mimic an "Add To Cart" or "Add To Checkout" button using the information below. 

Add to Checkout:

Important Note: The direct to checkout links below only work for the Shopify checkout. If you're using OneClickUpsell checkout, use this link structure instead.

URL structure to add 1 product to the Checkout:


Where 1234567890 is the product's Variant ID and 1 is the quantity.

URL structure to add multiple products to the Checkout:


Note: You can enter a different quantity for each product's Variant ID in the URL string above.

URL structure to add a Discount code to the Checkout along with the product(s):


Where you append the URL string with ?discount= then enter your Shopify discount code you want auto-applied. 

URL structure to add a product to the Checkout that is only visible to the Buy Button sales channel within your store:


Where you append the URL string with ?channel= then enter the Sales Channel that this product is visible to, in this case buy_button

Add to Cart:

URL structure to add 1 product to the Cart:


Where 1234567890 is the product's Variant ID and 1 is the quantity. 

URL structure to add multiple products to the Cart:


Note: Notice the use of [] in the URL string above. You can't apply different quantities for each product Variant ID. The quantity used at the end of the url above will be applied to ALL product Variant IDs added to the URL string. 

Using the Zipify OneClickUpsell Checkout?

If you're using the OCU app as well, then we have an integration that can be enabled within the Settings > Integrations section of the Zipify Pages app. 

With this integration enabled, OCU checkout can be initiated directly from:

  1. A Buy Box block that is set to either "Cart" or "Checkout".
    Note: For the "Cart" option to work, the "Skip Cart Page" setting will also need to be enabled within the OCU app (Settings > General > Advanced Settings > Skip Cart Page). 

  2. A standard Shopify checkout permalink I.e. yourstore.myshopify.com/cart/1234567890:1 that is added to your ZP page.
    Note: The link needs to be included and clicked on a ZP page specifically in order to initiate OCU checkout.

If you are not using the OCU integration for ZP or want a link that can be used anywhere else on the web other than a ZP page, then use the following link type instead. 

OCU checkout permalink structure example:


Where 1234567890 is the product variant ID and 1 is the quantity

You can also append a Shopify discount code at the end and have it auto-apply at OCU checkout like this for example:

Where CODE is the Shopify discount code you want auto-applied.

The way this link works is that it adds the product(s) to the cart then does an auto-redirect to OCU checkout. It works in most cases, but sometimes directs to Shopify checkout (depending on the theme being used on your store).

So we recommend to set one up and then test how it works on your store (use Private/Incognito browser mode) and to see if you get the OCU checkout or Shopify checkout. If you get OCU checkout then congratulations, your theme works with it!

Finding the Shopify Variant ID:

Method 1:

If you have added the Buy Button sales channel to your online store, you can find the variant ID by following these steps:

1. Navigate to the Product in your Shopify admin.

2. Click the "More actions" dropdown menu and select "Create checkout link".

3. Find the specific variant ID from the generated link on the next screen as seen here:

Method 2:

  1. Go to the product detail page on your storefront for the item you want to find the ID for.

  2. At the end of the URL there, enter .xml and press enter.

  3. The Shopify Variant ID you will need can be found as shown below:

4. After creating your link, click on it to make sure it functions correctly and adds the product(s) to the Cart or Checkout. If you get an error page, that means you have an incorrect variant ID included in your link. Go back to the .xml view of the page to try the next variant ID listed there instead. Then test the link again to ensure it works correctly. 

Did this answer your question?