Getting started with Shopify

read
Last updated at:

You will learn

Learn how to enable Klaviyo’s Shopify integration in order to bring your customer profile and order data into Klaviyo and reach customers with targeted messaging. This guide walks through collecting email and SMS subscribers, syncing your Shopify newsletter or sign-up form subscribers to a Klaviyo list, adding metrics from Shopify to Klaviyo, and enabling Klaviyo tracking for customers and their viewed products to your Shopify store. Adding the Shopify integration, and configuring specific settings, will automatically bring all of this data into Klaviyo.

There are two ways to get started with Klaviyo’s Shopify integration:

  • Add the Shopify integration from the Klaviyo Setup Wizard (if you’re a brand new customer).
  • Add the Shopify integration from the Integrations tab in Klaviyo.

The following instructions walk through adding the Shopify integration from the Integrations tab in your Klaviyo account.

Add the Shopify integration

  1. In Klaviyo, select your account name in the lower left. Then, click Integrations.
  2. Search for Shopify, then click Add Integration to view the integration settings page.
    Shopify listing on Klaviyo integration settings page with Add Integration
  3. Paste the URL of your Shopify store in the box. Make sure that it is in the format mystore.myshopify.com.
    Shopify integration settings page in Klaviyo showing onsite tracking section, sync data from Shopify section, and sync data to Shopify section
  4. You will be prompted to configure onsite tracking after connecting to Shopify, so this section will not yet be available.
  5. Check the Sync your Shopify email subscribers to Klaviyo box to automatically add all customers who accept email marketing at checkout and submit their information, or sign up to any Shopify sign-up form, to the list you select from the dropdown.
  6. Select a list to add email subscribers to from the dropdown, such as your Newsletter list, if you selected this setting.
  7. Check the Sync your Shopify SMS subscribers to Klaviyo box to automatically add all customers who accept SMS marketing at checkout to the list you select from the dropdown.
  8. Select a list to add SMS subscribers to from the dropdown, if you selected this setting.
  9. Check the setting Sync profiles and profile data from Klaviyo to Shopify if you want to sync any data. We recommend syncing all profiles and all types of data to Shopify. If you checked this setting, do the following:
    1. Choose whether to sync updates for either all Klaviyo profiles, or only for profiles that already exist in Shopify.
      If you choose all profiles, Klaviyo will create new customers in Shopify for all profiles (existing and new) created in Klaviyo. This includes profiles synced from other Klaviyo integrations, or added through list imports, even if they have not interacted with your Shopify store.
    2. Choose which profile data you’d like to sync: Name, email address, and phone number, Email subscription status, and SMS subscription status (if you have SMS enabled).  
  10. After configuring your settings, click Connect to Shopify. This will take you to your Shopify account. You may be prompted to log in to Shopify.
  11. After being brought into Shopify, review the permissions and click Install app. This begins syncing your Shopify data with Klaviyo and takes you back into your Klaviyo account.

    List of permissions requested by Klaviyo in Shopify with Install app in lower right

  12. A green success callout will indicate that your data is syncing with Klaviyo. When your sync finishes depends on the amount of data; see the section below on monitoring the historical data sync for more detailed information.
  13. Finally, enable onsite tracking by toggling on the Klaviyo app embed in Shopify. Do this by scrolling to the Onsite Tracking section of the integration settings page, where you’ll see a message noting that your Klaviyo app embed is not yet enabled. Click the link labeled view your App Embed setting here to be brought into Shopify. 

    Onsite tracking section of Shopify integration settings page in Klaviyo with yellow callout showing that the app embed is not yet enabled

  14. Note that the setting to enable Viewed Product is checked by default, so Viewed Product will start tracking once you enable the app embed. 
  15. After being brought to your theme settings, make sure the app embed is toggled on and then click Save.

    Klaviyo app embed in Shopify theme settings toggled on

  16. To check that your onsite tracking setup is complete, navigate back to your Shopify integration settings page in Klaviyo (click your account name in the lower left corner, select Integrations, then find your Shopify integration and click View Settings), where you’ll see a blue callout stating that your app embed is now enabled. 
  17. You’ve now integrated Klaviyo with Shopify and set up onsite tracking. 

    Onsite tracking section of Shopify integration settings page in Klaviyo with green callout showing that the app embed is enabled

Test onsite tracking

Klaviyo onsite tracking is comprised of two features: Active on Site and Viewed Product tracking. To confirm that they are working, follow these steps:

  1. Navigate to your Shopify site
  2. On your homepage, add the following to the end of the URL, replacing example@gmail.com with your email address:
    ?utm_email=example@gmail.com
  3. Reload the page
  4. Navigate to a product page on your site
  5. Search in Klaviyo for your email address

You will see that a Klaviyo profile has been created for you (if one didn't exist already), and that Active on Site and Viewed Product metrics have been tracked on your activity feed.

More information about Shopify settings

Here, we give more details about Shopify settings. If you ever need to update these settings, you can return to the integration settings page by clicking your account name in the lower left corner, selecting Integrations, finding your Shopify integration, and clicking View Settings. Then, make your changes and click Update Settings.

Onsite tracking

The Klaviyo app embed for the Shopify Theme Editor enables Klaviyo onsite tracking for both vintage and Shopify 2.0 themes. After integrating with Shopify and installing the Klaviyo app, toggle on the Klaviyo app embed for your store by following the instructions in the section below. 

There are two key types of Klaviyo onsite tracking: Active on Site and Viewed Product tracking. Using these tracking events can help you engage identifiable browsers of your store. Additionally, enabling Active on Site tracking will allow you to use Klaviyo sign-up forms. Checking the Viewed Product setting will enable Viewed Product tracking for your store once the app embed is toggled on. 

To learn more about Klaviyo onsite tracking and the Shopify app embed, read our article on Klaviyo onsite tracking for Shopify. Note that the app embed for your Klaviyo account can only be associated with one Shopify store. 

Based on your Customer Privacy settings in Shopify, Klaviyo may not track onsite events (including Active on Site and Viewed Product) for visitors to your Shopify store in the EU, EEA, UK and Switzerland, unless they have provided consent.

Email subscribers

On December 14th, 2022, Klaviyo released an update changing the way email subscribers are synced from Shopify to Klaviyo. This sync previously relied on Shopify’s Accepts Marketing tag, but now, subscribers are synced via Shopify’s subscription model. Klaviyo still syncs the Accepts Marketing tag from Shopify, and your pre-existing subscribers synced before this release are not affected by these changes. To learn more about the Accepts Marketing property to understand pre-existing subscribers, read the section below.

Contacts being created in Shopify for the first time are now subscribed at the Checkout Started step, once they submit their data. Existing contacts in Shopify will need to place an order to be subscribed.

It's important to add your Shopify subscribers automatically to your Klaviyo newsletter list in order to easily build a list of consented subscribers to send to. New newsletter subscribers will sync in real time through your Shopify integration. 

If a profile consents to email marketing in Shopify, they will be consented to email marketing in Klaviyo. This status appears on individual profiles in Klaviyo, and a Subscribed to List event is recorded in Klaviyo. 

If a profile is unsubscribed in Shopify, they will not be unsubscribed in Klaviyo. Additionally, if a Klaviyo profile is already subscribed but does not consent at checkout, they will not be unsubscribed in Klaviyo (no change will happen).  If a profile is unsubscribed in Klaviyo, and then resubscribes at checkout, they will be resubscribed in Klaviyo. 

SMS subscribers

Collecting SMS consent from customers during checkout allows you to drastically grow your SMS subscriber list. It is also a straightforward, non-intrusive way to gain consent. You will only be able to collect SMS consent from recipients in countries where Klaviyo SMS is available.

If you are also collecting email subscribers, assign a separate list to each channel. This ensures that consent is applied properly when subscribers sync into Klaviyo. For more information, read How to collect SMS consent at checkout on Shopify

Note that consent will only sync to Klaviyo if the person is subscribing to SMS in Shopify for the first time.

Sync data to Shopify

Here, select which profiles to sync updates from Klaviyo to Shopify for (all profiles, or profiles that already exist in Shopify) and which fields should sync. Once you configure these settings, the following fields will only sync if they were previously empty for an existing customer in Shopify: first name, last name, email, and phone number. The fields from Klaviyo that will overwrite pre-existing fields in Shopify are email subscription status and SMS subscription status.

We recommend syncing all profiles and all types of data to Shopify. You can read more about syncing Klaviyo data to Shopify in our dedicated article.

Monitor your data sync

When you first integrate with Shopify, Klaviyo will sync the last 90 days of your Shopify data so you can start engaging your most recent customers. After the sync of the last 90 days of data, Klaviyo will begin your complete historical data sync. Depending on how many orders, customers, and products your store has, it can take anywhere from a few minutes to several days to sync all of your data, and a green progress bar will show the progress of your sync.

Once this historical sync is complete, new data will sync to Klaviyo in real time. To check the progress of the initial sync:

  1. Click the Analytics dropdown and select Metrics.
  2. Find the Placed Order metric and change the date range of the graph to see which dates have been fully synced. When the sync is complete, the Shopify integration in the Integrations tab will be marked complete.
  3. To verify for yourself that all data from Shopify is synced, you can cross check the total orders for a few days or a week. Before you start validating, make sure your account's timezone matches the settings in Shopify.
  4. To check or update your account's timezone, go to the Account Settings page (found by clicking your account name in the lower left, then clicking Settings) navigate to Contact Information > Organization and scroll down to Timezone.

About sign-up forms with Shopify

Klaviyo’s Shopify integration provides three options for syncing your sign-up forms to Klaviyo:

  • Sync your default Shopify sign-up forms to a Klaviyo list (this happens when you check the Sync your Shopify email subscribers to Klaviyo setting during integration setup)
  • Add a Klaviyo form to your Shopify store
  • Integrate a 3rd party sign-up form provider to your Klaviyo account.

If you set up Active on Site tracking already (either via the app embed, the since-deprecated integration setting, or manually) you can start using Klaviyo sign-up forms right away. This is because the same code snippet that enables Active on Site tracking (known as "Klaviyo.js") also enables our sign-up forms. 

About the Accepts Marketing property

On December 14th, 2022, Klaviyo released an update changing the way email subscribers are synced from Shopify to Klaviyo. This sync previously relied on Shopify’s Accepts Marketing tag, but now, subscribers are synced via Shopify’s subscription model. If you are looking to understand your Shopify subscribers synced before this release, read on to learn more about the Accepts Marketing tag. 

Below is an example of how the property appears on a customer's profile in Klaviyo. To find a list of profiles in Klaviyo and view their details, click the Audience dropdown and select the Profiles tab. You can also use the search bar to search for individual profiles. 
shop7.jpg

To learn how the Accepts Marketing property is managed in Shopify, see their documentation. There are a few situations which can cause a pre-existing customer to have Accepts Marketing set to false, but they're still subscribed to your newsletter:

  • If a customer checks out and decides not to accept email marketing at that time, but later subscribes through a Klaviyo sign-up form, they'll still be added to your newsletter list.
  • If a customer checks out and does accept email marketing, they'll be added to your newsletter list. If they check out again, they'll probably decide to not subscribe again since they're already subscribed. Depending on your checkout configuration, Shopify might see this as not accepting marketing (Accepts Marketing = false.) You probably don't want to treat this customer as an unsubscribe. Rather, you'll want to keep this customer on your newsletter list. 

Klaviyo will not automatically sync historical subscribers to a list when you check Collect email subscribers. If you need to add historical subscribers to your newsletter list, you can do so by uploading a CSV as outlined in How to add or combine lists without triggering a flow

Additionally, it's important to note that a pre-existing customer who has Accepts Marketing set to false won't automatically be suppressed. To learn more about suppression, check out our article Understanding suppressed email profiles.

Troubleshooting

If you are having trouble with your Shopify integration, check out our article Troubleshooting your Shopify integration

Outcome

You've now integrated Shopify with Klaviyo, enabled onsite tracking, and learned all about Shopify integration settings.

Additional resources

x
Was this article helpful?
2484 out of 3829 found this helpful