SH

Shopify Buy Button

By Shopify

9.3/ 10

Sell Shopify products from any website without building a full store. Includes cart and checkout.

🛍️

E-Commerce

Product listings, stores, and payment widgets.

Browse category

Parameters

STORErequired

Shopify store subdomain

Default: mystore

TOKENrequired

Storefront access token

Default: your_token_here

PRODUCT_IDrequired

Shopify product ID

Default: 12345678901234

Embed Code

Customize:
html
<div id="product-component-ID"></div>
<script type="text/javascript">
/*<![CDATA[*/
(function () {
  var scriptURL = 'https://sdks.shopifycdn.com/buy-button/latest/buy-button-storefront.min.js';
  if (window.ShopifyBuy) {
    if (window.ShopifyBuy.UI) { ShopifyBuyInit(); } else { loadScript(); }
  } else { loadScript(); }
  function loadScript() { var script = document.createElement('script'); script.async = true; script.src = scriptURL; document.head.appendChild(script); }
  function ShopifyBuyInit() {
    var client = ShopifyBuy.buildClient({ domain: 'STORE.myshopify.com', storefrontAccessToken: 'TOKEN' });
    ShopifyBuy.UI.onReady(client).then(function (ui) { ui.createComponent('product', { id: 'PRODUCT_ID', node: document.getElementById('product-component-ID') }); });
  }
})();
/*]]>*/
</script>

Live Preview

SH

Shopify Buy Button

Live preview requires your own credentials. Copy the embed code, replace the placeholder values, and paste into your site.