Warehouses and Lakes
Marketing Analytics

How to load data from Klaviyo to BigQuery destination

Learn how to use Airbyte to synchronize your Klaviyo data into BigQuery destination within minutes.


This can be done by building a data pipeline manually, usually a Python script (you can leverage a tool as Apache Airflow for this). This process can take more than a full week of development. Or it can be done in minutes on Airbyte in three easy steps:

  1. set up Klaviyo as a source connector (using Auth, or usually an API key)
  2. set up BigQuery destination as a destination connector
  3. define which data you want to transfer and how frequently

You can choose to self-host the pipeline using Airbyte Open Source or have it managed for you with Airbyte Cloud.

This tutorial’s purpose is to show you how.

What is Klaviyo

Klavivo is a communications platform aimed at helping businesses grow through email and marketing automation. Klavivo does the granular work, from personalized newsletters and thank you’s to automated emails reminding visitors of abandoned carts and order follow-ups—so businesses don’t have to spend time on the little details. An inexpensive solution for businesses to customize email marketings campaigns, it integrates with a customer’s data sources at scale and allows brands to measure their results.

What is BigQuery destination

BigQuery is an enterprise data warehouse that draws on the processing power of Google Cloud Storage to enable fast processing of SQL queries through massive datasets. BigQuery helps businesses select the most appropriate software provider to assemble their data, based on the platforms the business uses. Once a business’ data is acculumated, it is moved into BigQuery. The company controls access to the data, but BigQuery stores and processes it for greater speed and convenience.


  1. A Klaviyo account to transfer your customer data automatically from.
  2. A BigQuery destination account.
  3. An active Airbyte Cloud account, or you can also choose to use Airbyte Open Source locally. You can follow the instructions to set up Airbyte on your system using docker-compose.

Airbyte is an open-source data integration platform that consolidates and streamlines the process of extracting and loading data from multiple data sources to data warehouses. It offers pre-built connectors, including Klaviyo and BigQuery destination, for seamless data migration.

When using Airbyte to move data from Klaviyo to BigQuery destination, it extracts data from Klaviyo using the source connector, converts it into a format BigQuery destination can ingest using the provided schema, and then loads it into BigQuery destination via the destination connector. This allows businesses to leverage their Klaviyo data for advanced analytics and insights within BigQuery destination, simplifying the ETL process and saving significant time and resources.

Step 1: Set up Klaviyo as a source connector

1. First, navigate to the Klaviyo source connector page on Airbyte.com.

2. Click on the "Add Source" button to begin the process of adding your Klaviyo credentials.

3. Enter a name for your Klaviyo source connector and click on the "Next" button.

4. You will be prompted to enter your Klaviyo API key. To obtain your API key, log in to your Klaviyo account and navigate to the "API Keys" section under "Account Settings."

5. Click on the "Create API Key" button and copy the generated key.

6. Paste the API key into the Airbyte Klaviyo source connector page and click on the "Test" button to ensure that the connection is successful.

7. Once the connection is successful, click on the "Next" button to proceed to the next step.

8. Select the data you want to replicate from Klaviyo and click on the "Next" button.

9. Choose the destination where you want to replicate your Klaviyo data and click on the "Create Connection" button.

10. Your Klaviyo source connector is now set up and ready to replicate data to your chosen destination.

Step 2: Set up BigQuery destination as a destination connector

1. First, navigate to the Airbyte dashboard and select the "Destinations" tab on the left-hand side of the screen.

2. Scroll down until you find the "BigQuery" destination connector and click on it.

3. Click the "Create Destination" button to begin setting up your BigQuery destination.

4. Enter your Google Cloud Platform project ID and service account credentials in the appropriate fields.

5. Next, select the dataset you want to use for your destination and enter the table prefix you want to use.

6. Choose the schema mapping for your data, which will determine how your data is organized in BigQuery.

7. Finally, review your settings and click the "Create Destination" button to complete the setup process.

8. Once your destination is created, you can begin configuring your source connectors to start syncing data to BigQuery.

9. To do this, navigate to the "Sources" tab on the left-hand side of the screen and select the source connector you want to use.

10. Follow the prompts to enter your source credentials and configure your sync settings.

11. When you reach the "Destination" step, select your BigQuery destination from the dropdown menu and choose the dataset and table prefix you want to use.

12. Review your settings and click the "Create Connection" button to start syncing data from your source to your BigQuery destination.

Step 3: Set up a connection to sync your Klaviyo data to BigQuery destination

Once you've successfully connected Klaviyo as a data source and BigQuery destination as a destination in Airbyte, you can set up a data pipeline between them with the following steps:

  1. Create a new connection: On the Airbyte dashboard, navigate to the 'Connections' tab and click the '+ New Connection' button.
  2. Choose your source: Select Klaviyo from the dropdown list of your configured sources.
  3. Select your destination: Choose BigQuery destination from the dropdown list of your configured destinations.
  4. Configure your sync: Define the frequency of your data syncs based on your business needs. Airbyte allows both manual and automatic scheduling for your data refreshes.
  5. Select the data to sync: Choose the specific Klaviyo objects you want to import data from towards BigQuery destination. You can sync all data or select specific tables and fields.
  6. Select the sync mode for your streams: Choose between full refreshes or incremental syncs (with deduplication if you want), and this for all streams or at the stream level. Incremental is only available for streams that have a primary cursor.
  7. Test your connection: Click the 'Test Connection' button to make sure that your setup works. If the connection test is successful, save your configuration.
  8. Start the sync: If the test passes, click 'Set Up Connection'. Airbyte will start moving data from Klaviyo to BigQuery destination according to your settings.

Remember, Airbyte keeps your data in sync at the frequency you determine, ensuring your BigQuery destination data warehouse is always up-to-date with your Klaviyo data.

Use Cases to transfer your Klaviyo data to BigQuery destination

Integrating data from Klaviyo to BigQuery destination provides several benefits. Here are a few use cases:

  1. Advanced Analytics: BigQuery destination’s powerful data processing capabilities enable you to perform complex queries and data analysis on your Klaviyo data, extracting insights that wouldn't be possible within Klaviyo alone.
  2. Data Consolidation: If you're using multiple other sources along with Klaviyo, syncing to BigQuery destination allows you to centralize your data for a holistic view of your operations, and to set up a change data capture process so you never have any discrepancies in your data again.
  3. Historical Data Analysis: Klaviyo has limits on historical data. Syncing data to BigQuery destination allows for long-term data retention and analysis of historical trends over time.
  4. Data Security and Compliance: BigQuery destination provides robust data security features. Syncing Klaviyo data to BigQuery destination ensures your data is secured and allows for advanced data governance and compliance management.
  5. Scalability: BigQuery destination can handle large volumes of data without affecting performance, providing an ideal solution for growing businesses with expanding Klaviyo data.
  6. Data Science and Machine Learning: By having Klaviyo data in BigQuery destination, you can apply machine learning models to your data for predictive analytics, customer segmentation, and more.
  7. Reporting and Visualization: While Klaviyo provides reporting tools, data visualization tools like Tableau, PowerBI, Looker (Google Data Studio) can connect to BigQuery destination, providing more advanced business intelligence options. If you have a Klaviyo table that needs to be converted to a BigQuery destination table, Airbyte can do that automatically.

Wrapping Up

To summarize, this tutorial has shown you how to:

  1. Configure a Klaviyo account as an Airbyte data source connector.
  2. Configure BigQuery destination as a data destination connector.
  3. Create an Airbyte data pipeline that will automatically be moving data directly from Klaviyo to BigQuery destination after you set a schedule

With Airbyte, creating data pipelines take minutes, and the data integration possibilities are endless. Airbyte supports the largest catalog of API tools, databases, and files, among other sources. Airbyte's connectors are open-source, so you can add any custom objects to the connector, or even build a new connector from scratch without any local dev environment or any data engineer within 10 minutes with the no-code connector builder.

We look forward to seeing you make use of it! We invite you to join the conversation on our community Slack Channel, or sign up for our newsletter. You should also check out other Airbyte tutorials, and Airbyte’s content hub!

An important part of business marketing strategy is analyzing how your customer acquisition (or onboarding) campaigns perform. Many tools exist in the market that can help you automate some parts of the job. One such tool is Klaviyo which provides powerful tools like campaign management to engage with your new customers successfully.

With time, the user data tends to increase, needing large-scale analytics over over bigger datasets and requiring you to set up a data warehouse pipeline. Tools like BigQuery, and Snowflake are reliable options. Google BigQuery is a fully managed serverless data warehouse that provides scalable analysis over large datasets. BigQuery also offers real-time analysis of data.

In this tutorial, we will look at how you can move data from Klaviyo to BigQuery without any manual work, fully automated with Airbyte.

Why Klaviyo?

Klaviyo is an E-Commerce marketing automation platform that has several benefits.

  • Klaviyo gives online brands direct ownership of their consumer data and interactions, empowering them to turn transactions with customers into long-term relationships—at scale.
  • With Klaviyo, brands can combine unlimited customer data with more than 250 native integrations to automate personalized email and SMS communications that make customers feel seen.
  • Klaviyo makes it easy—no need to start from scratch, piece together multiple platforms, or rely on third-party marketplaces and ad networks.
  • From mom-and-pop shops to established companies, innovative brands like Unilever, Bonobos, Taylor Made, Citizen Watches, and more than 90K other paying users leverage Klaviyo to acquire, engage, and retain customers—and grow on their own terms.


  1. A Klaviyo account to transfer your customer data from.
  2. A Google cloud account to create our BigQuery data warehouse.
  3. An active Airbyte cloud account, or you can also choose to use Airbyte locally. You can follow the instructions to set up Airbyte on your system using docker-compose.

Step 1: Setup Klaviyo as an Airbyte source

To set up Klaviyo, login to your dashboard and head over to settings from the left-hand side menu bar.

Once you navigate to the settings page, choose the API Keys option from the top bar.

You will now be able to see two different sections of API keys. One of which is a public key (or site ID) which is usually embedded with the signup forms. To export data from Klaviyo to Airbyte, we need a Private Key instead. Click on the Create Private Key button to generate one.

You should see that Klaviyo has added a new row in the private keys table. You can choose to add a label to this key in case you have multiple third-party integrations set up.

Now head over to your Airbyte Dashboard and, from Sources, select Klaviyo as a new source. Add the API key, which we just created. For the start date, you can add the date you created the Klaviyo account.

Once you are satisfied with your changes, choose the Set-up source button.

Step 2: Setup BigQuery as Airbyte Destination

To set up a big query Airbyte destination, ensure you are logged in to your Google cloud dashboard. Now we need to create a BigQuery dataset to load our customer data to BigQuery.

From the main page, choose the Run a query in BigQuery button.

From the 3-dot menu of your cloud project, choose the only option to create a dataset

For Dataset ID, choose a descriptive name like kalviyo_dataset. Only alphanumeric names are allowed as dataset ID names.

Choose the dataset location from the menu and click Create Dataset. You should now be able to see a newly created dataset. Take note of the Dataset ID that you just entered, since we will need it, later on, to set up BigQuery as an Airbyte Destination.

The only thing left to do is get the appropriate account keys to access our BigQuery project. Choose API & Services from the Quick Access menu in your cloud dashboard.

From the credential menu, choose to create a new Service account.

Choose a valid name for your Service account.

We need to tell google about what resources can be accessed from this service account. From the available roles, choose BigQuery Admin.

Click Done, and you should see a new service account.

Choose this newly created service account email and add a new key by clicking on the Add Key button.

From the Create private key pop-up, choose JSON.

Once you choose to Create, a new file must have been downloaded to your system. The final step involves creating a new Airbyte destination.

From your Airbyte dashboard, choose Destinations and choose New Destination, and pick BigQuery from the available options.

Under Service Account Key JSON, copy the value from the credentials file.

Step 3: Setup Airbyte connection from Klaviyo to BigQuery

Go to Connections in your dashboard and pick New connection. From the existing source & destinations available, pick the ones which we just created. Once you select the source & destinations, you should see the connection information like this

As you can see, Airbyte is providing us six different available streams to sync data from including campaigns, event flows, global_exclusions, lists, and metrics. You can choose to disable streams to sync data by clicking on the toggle button.

For sync mode, select one from the available modes. A sync mode defines how the data should be stored to the destination. A Full Refresh - Overwrite will overwrite data at the destination, whereas an Incremental mode will sync new records from the source and add them to the destination without overwriting previous data. You can learn more about sync modes in our documentation.

You can choose to set up a connection once you are satisfied with the connection configuration. If you choose Replication frequency as Manual, you will have to start the sync manually.

Once the sync completes, you will be able to see new tables that were created by Airbyte in your BigQuery project.

Choose a table to preview its contents and schema.

As you can see, Airbyte successfully synchronized two of our sample campaigns from our Klaviyo account.

The real power of BigQuery is being able to run SQL queries over datasets. Here is a sample query to list our campaigns

Wrapping Up

To summarize, this tutorial has shown you how to:

  1. Configure a Klaviyo account as an Airbyte source via their API.
  2. Configure a data warehouse using Google BigQuery.
  3. Create an Airbyte connection that automatically syncs (or migrates) data from a Klaviyo to BigQuery.

With Airbyte, the data integration possibilities are endless, and we look forward to seeing you make use of it! We invite you to join the conversation on our community Slack Channel, to participate in discussions on Airbyte’s discourse, or sign up for our newsletter. You should also check out other Airbyte tutorials, and Airbyte’s blog!

Frequently Asked Questions

What data can you extract from Klaviyo?

Klaviyo's API provides access to a wide range of data related to email marketing and e-commerce. The following are the categories of data that can be accessed through Klaviyo's API:  

1. Profiles: This includes information about individual subscribers, such as their email address, name, location, and other demographic data.  

2. Lists: This includes information about the different email lists that are managed within Klaviyo, such as the number of subscribers, the date they were added, and their engagement metrics.  

3. Campaigns: This includes information about the different email campaigns that have been sent, such as the subject line, the content, and the performance metrics.  

4. Metrics: This includes data related to the performance of email campaigns, such as open rates, click-through rates, and conversion rates.  

5. Events: This includes data related to specific actions taken by subscribers, such as making a purchase, abandoning a cart, or signing up for a newsletter.  

6. Products: This includes information about the products that are sold through an e-commerce store, such as their name, price, and availability.  

7. Orders: This includes information about the orders that have been placed by customers, such as the order number, the date, and the total amount.

What data can you transfer to BigQuery destination?

You can transfer a wide variety of data to BigQuery destination. This usually includes structured, semi-structured, and unstructured data like transaction records, log files, JSON data, CSV files, and more, allowing robust, scalable data integration and analysis.

What are top ETL tools to transfer data from Klaviyo to BigQuery destination?

The most prominent ETL tools to transfer data from Klaviyo to BigQuery destination include:

  • Airbyte
  • Fivetran
  • Stitch
  • Matillion
  • Talend Data Integration

These tools help in extracting data from Klaviyo and various sources (APIs, databases, and more), transforming it efficiently, and loading it into BigQuery destination and other databases, data warehouses and data lakes, enhancing data management capabilities.