Shopify Buy Button: How To Add Ecommerce Features To Any Website In 3 Steps


Shopify isn’t just for full-fledged ecommerce businesses. Anyone looking to monetize their projects⁠—be they bloggers, artists, writers, designers, podcasters, or influencers⁠—stands to benefit from selling online.

But setting up an online store takes time, and redirecting web traffic adds friction to the checkout process that could negatively impact your sales. Luckily, there’s a solution.

With the Shopify Buy Button, you can fully integrate Shopify’s ecommerce tools with any website, whether it’s built on WordPress, Squarespace, Wix or any other website builder.

Here’s how:

1. Add the Buy Button sales channel to your Shopify store

You’ll want to start by logging in to your Shopify store. If you see the Buy Button listed under your Sales Channels on the left side menu, then the sales channel has already been added and you can skip ahead to step 2.

Sales channel menu in Shopify admin showing Buy Button enabled
Skip to step 2 if you already see the Buy Button sales channel listed in your store.

On desktop

  1. Go to the Buy Button sales channel page in the Shopify App Store (you can also get to this page by going to Settings > Visit the Shopify App Store and searching Buy Button⁠).
  2. Click Add app, then Add Sales Channel on the next screen.

Add Sales Channel screen on the Shopify Admin showing Buy Button being added

After the page refreshes, you should see Buy Button listed under Sales channels on the left-side menu. Be sure to pin the channel to your navigation for easy access down the road.

Animated gif showing Buy Button sales channel being pinned to Shopify Admin

If you don’t pin the Buy Button, you can find it again by clicking on Sales Channels and then Buy Button under your installed channels.

On mobile

  1. Open the Shopify app on your mobile device and select Store from the bottom menu.
  2. Next to Sales channels, select Add channel (on iPhone) or + (on Android).
  3. Select Buy Button from the list of options, then tap Add Buy Button.

Add Buy Button screen on Shopify mobile app

2. Create a Buy Button

Once you’ve added the Buy Button sales channel, you’re ready to start creating your Buy Button. Navigate to your Buy Button page by clicking Buy Button (if you pinned it to your navigation) or by going to Settings > Apps and sales channels > Buy Button.

From there, click Create a Buy Button.

Create a Buy Button screen in the Shopify Admin

You can create Buy Buttons for either a single product, or a whole collection of products. On the next screen, you’ll be asked to select which option you prefer. Click your preferred option, then search for the product or collection you want to use to create your Buy Button.

Make sure the checkbox is filled and click Select.

Screenshot of product selection window in the Shopify Admin when creating a Buy Button

Once you’ve made your selection, you’ll be brought to the Buy Button editor, where you can customize the look of your Buy Button.

How to Customize your Buy Button

In the Buy Button editor, you’ll see a number of options listed on the left-hand side for customizing the look and feel of your Buy Button. On the right, you will see a preview of what your Buy Button will look like.

Customize Shopify Buy Button screen in the Shopify Admin

Adjust the options on the left to your liking. Your preview will update with the adjustments automatically, so you can see what your Buy Button looks like as you’re creating it. In the preview, you’ll be able to view how your Buy Button will appear on both desktop and mobile screens by clicking the desktop or mobile icons, centered at the top of the editor.

Here is a breakdown of the options you can customize:

  • Product variant: Select which variants of the product you want to be purchasable through the Buy Button. All variants will be selected by default.
  • Layout: Choose between Basic, Classic, and Full view. You’ll see a preview of each layout on the right when you select it from the Layout drop-down.
  • Action when people click: Choose between “Add product to cart,” “Direct to checkout,” or “Open product details.” The “Add product to cart” option will create a cart widget on the right side of your screen. The “Direct to checkout” option will create a Buy Now button that will take a user directly to checkout (note that customers won’t be able to add more than one item to their cart using this option). The “Open product details” option will create a View Product button that opens a pop-up that includes product information and an Add to Cart button.
  • Button style: Here you can adjust the colors, font, size, and corner shape of your Buy Button.
  • Layout: The Layout menu will allow you to make finer adjustments to the layout of your button. You can customize font colors, button text, and typography settings.
  • Shopping cart: Here you’ll be able to adjust the settings of your shopping cart widget, including copy and colors. Note that this option will be grayed out if you use the “Direct to checkout” layout, since there is no cart widget.
  • Detailed pop-up: If you select “Open product details” under “Action when people click,” you’ll be able to customize the text, colors, and typography options for the pop-up in this section.
  • Advanced settings: Here you can adjust how your checkout is served to your user. You can either select “Open pop-up window” (which will create a pop-up checkout that closes when the order is complete), or “Redirect in the same tab” (which will send the user to your Shopify checkout page from within their browser window, and return them to your page once the transaction is complete).

Remember that adjusting these settings will not change Buy Buttons that have already been embedded. That’s why it’s good to take some time to adjust the Buy Button to your liking before moving on to the next step.

Shopify Buy Button customization screen showing customized Buy Button design

When you’re happy with your design, click the Next button in the top right corner.

3. Add the Buy Button embed code to your website’s HTML

When you click Next, your Buy Button will automatically generate the embed code. Click the Copy Code button if you’re ready to embed it on a webpage or the Keep Customizing button if you want to go back to the Buy Button editor to make adjustments.

The code you’ve copied here can be pasted into the HTML of any webpage and it will create a Buy Button and cart that will connect directly to your Shopify admin, allowing you to manage and process orders from any webpage from within your Shopify admin.

The process of adding the embed code can be a little different, depending on how you want the button to appear, the website builder you’re using, or even the theme you’re using on the platform.

Here’s a breakdown of some of the more common places to embed a Shopify Buy Button and what steps you’d need to follow to do so:

Add embed code to a landing page or blog post on your Shopify store

Your Shopify store will already have product pages and a cart built in. Still, occasionally there may be situations where you’d like to add a Buy Button directly into a page or blog post for added convenience.

For example, if you were writing a blog post about a newly released product, you may want to give readers an easy way to purchase directly from the post rather than linking them to a separate page.

In cases like these, here are the steps you’ll want to follow:

    1. From your Shopify admin, go to Online Store > Blog Posts or Online Store > Pages, depending on whether you add it to a blog post or page.
    2. Select the blog post or page to which you want to add the Buy Button.
    3. In the Content window, select the <> button to switch from the Edit view to the HTML view.

Shopify Admin page editor highlighting the Switch to HTML tab

  1. Paste your embed code you copied earlier into the HTML editor, wherever you’d like it to appear. Click Save.

Screenshot showing Buy Button embed code in the HTML view of the blog editor.

Once you’ve saved your page or blog post, your Buy Button will be added to the page. If you want to see what it looks like without publishing, select Preview (or View page if you’re adding it to a page) at the top right corner of the page editor.

Screenshot of Shopify Buy Button on blog post

Add a Buy Button to a Squarespace website

On Squarespace, you can add your Buy Button to individual posts or to menus on your homepage. To add a Buy Button to your Squarespace site:

  1. Log into your Squarespace dashboard and open the page where you want to add a Buy Button.
  2. Hover over the Page Content area of the page element where you want the Buy Button to appear and click Edit.
  3. Select the insert point where you want to add the embed code.
  4. From the Content Blocks menu, under the More section, select Code.
  5. Ensure HTML is selected from the drop-down menu in the top right corner, and then paste the Buy Button embed code into the Code field.
  6. Click Apply.

Keep in mind that some custom Squarespace themes may require more advanced knowledge of HTML for customizations. In cases like these, it’s best to reach out to a developer directly for help adding custom code to your site.

Add a Buy Button to a WordPress blog

To add a Buy Button to a post on your site:

  1. From your WordPress dashboard, go to your posts and select the one to which you’d like to add a Buy Button.
  2. Depending on the version of the WordPress editor you’re using, complete one of the following steps:
    • If you’re using the Classic Editor for your WordPress site, click the Text tab in the editor to switch from Visual view to Text view.
    • If you’re using the Block Editor for your WordPress site, click the + button, then search and select Custom HTML.
  3. Paste the Buy Button embed code into the space where you’d like it to appear.
  4. Click Save Draft, Preview, or Publish, depending on the action you’d like to take.

You can also add the embed code to a WordPress menu by completing the following steps:

  1. From your WordPress dashboard, click Appearance.
  2. Select Customize to open the theme editor, then select Widgets.
  3. Select the area where you’d like to add your Buy Button.
  4. Click Add a Widget, then Text⁠.
  5. Paste the Buy Button embed code.
  6. Click Save & Publish.

Note that Shopify Buy Buttons are compatible with the platform but not with due to HTML customization limitations.

Add a Buy Button to Wix

To add a Shopify Buy Button to your Wix site, follow these steps:

  1. From your Wix dashboard, select the site from the My Sites page that you’d like to add the Buy Button to, and then select Edit Site.
  2. In the Wix website editor, click +, then More. Select HTML Code. This will add an HTML code widget to your page.
  3. Click Enter code. On the HTML Settings pop-up, paste your Buy Button embed code into the Add code here field.
  4. Click Apply.
  5. Adjust the size of the HTML code widget to your liking. Remember to make sure the cart tab is visible if you’ve embedded a Buy Button with a cart.
  6. When you’re finished adjusting, click Save.

It’s worth noting that if you want to embed Buy Buttons for multiple products, it’s best to embed a collection Buy Button, rather than a Buy Button for a single product. If you embed multiple single-product Buy Buttons, visitors will see a separate cart for each product.

Adding Shopify Buy Button script tags

In some cases, website builders (such as Unbounce) will require that you paste .

Once you have these elements separated, here are the steps to take:

  1. Open the page header for the website where you want to embed your Buy Button.
  2. Copy and paste the
Leave a Reply

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

Marketing Insight from Harley Quinn

Marketing Insight from Harley Quinn

Working For A Remote Company With Ezra Alamsyah

Working For A Remote Company With Ezra Alamsyah


Steve has entrepreneurship in his DNA. Starting in the early 2000s, Steve achieved eBay Power Seller status which propelled him to become a founding partner of, a contact lens and eyewear retailer. Four years later through a successful exit from that startup, he embarked on his next journey into digital strategy for direct-to-consumer brands.

Currently, Steve is a Senior Merchant Success Manager at Shopify, where he helps brands to identify, navigate and accelerate growth online and in-store.

To maintain his competitive edge, Steve also hosts the top-rated twice-weekly podcast eCommerce Fastlane. He interviews Shopify Partners and subject matter experts who share the latest marketing strategy, tactics, platforms, and must-have apps, that assist Shopify-powered brands to improve efficiencies, profitably grow revenue and to build lifetime customer loyalty.

You May Also Like
payday loans loans for bad credit
where can i buy clomid buy clomid