

Building your pipeline or Using Airbyte
Airbyte is the only open source solution empowering data teams to meet all their growing custom business demands in the new AI era.
- Inconsistent and inaccurate data
- Laborious and expensive
- Brittle and inflexible
- Reliable and accurate
- Extensible and scalable for all your needs
- Deployed and governed your way
Start syncing with Airbyte in 3 easy steps within 10 minutes



Take a virtual tour
Demo video of Airbyte Cloud
Demo video of AI Connector Builder
What sets Airbyte Apart
Modern GenAI Workflows
Move Large Volumes, Fast
An Extensible Open-Source Standard
Full Control & Security
Fully Featured & Integrated
Enterprise Support with SLAs
What our users say


"The intake layer of Datadog’s self-serve analytics platform is largely built on Airbyte.Airbyte’s ease of use and extensibility allowed any team in the company to push their data into the platform - without assistance from the data team!"


“Airbyte helped us accelerate our progress by years, compared to our competitors. We don’t need to worry about connectors and focus on creating value for our users instead of building infrastructure. That’s priceless. The time and energy saved allows us to disrupt and grow faster.”


“We chose Airbyte for its ease of use, its pricing scalability and its absence of vendor lock-in. Having a lean team makes them our top criteria. The value of being able to scale and execute at a high level by maximizing resources is immense”
Select the Data to Export
- Write a SQL query in BigQuery to select the data you want to export.
- Ensure that the data types in BigQuery are compatible with PostgreSQL data types.
Export to Google Cloud Storage
- Navigate to the BigQuery console.
- Run your query and click on the “Save Results” button.
- Choose “CSV” as the format and select your Google Cloud Storage bucket to export the data.
Download Data from Google Cloud Storage
- Go to the Google Cloud Storage console.
- Find your exported CSV file.
- Click on the file and then click on the “Download” button to save the file locally.
Install PostgreSQL
- If not already installed, download and install PostgreSQL from the official website or use a package manager for your operating system.
Create a Database and Table
- Log in to your PostgreSQL database using a tool like psql or PgAdmin.
- Create a new database or use an existing one.
- Create a table with the appropriate schema to match the data types and structure of the BigQuery data. For example:
CREATE TABLE your_table_name (
column1 datatype1,
column2 datatype2,
...
);
Convert CSV to PostgreSQL Format
Ensure your CSV file matches the PostgreSQL import format:
- The first line should contain column headers.
- Data should be properly escaped and quoted if necessary.
- Date and time formats should match PostgreSQL’s expected format.
Copy Data to PostgreSQL
Use the COPY command in PostgreSQL to import the data. You can do this from the psql command line or through a SQL execution tool. For example:
COPY your_table_name FROM '/path/to/your/file.csv' DELIMITER ',' CSV HEADER;
If you’re executing the command from a remote location, you might need to use a tool like scp or rsync to transfer the file to a location accessible by the PostgreSQL server.
Verify the Import
- Run a few SELECT queries to ensure that the data has been imported correctly.
- Check for any import errors and make sure the data types have been correctly interpreted.
Remove Temporary Files
- Delete the CSV file from your local machine if it’s no longer needed.
- Optionally, remove the exported data from Google Cloud Storage to avoid unnecessary storage charges.
Check for Consistency
- Perform a thorough check of the data in PostgreSQL to ensure it matches the original data in BigQuery.
- Look for any discrepancies or data integrity issues and address them accordingly.
Step 5: Optimize and Secure the Data Transfer Process
Automate the Process (Optional)
- To automate this process, you can write a script that runs these steps at a scheduled time.
- Make sure to handle errors and exceptions in your script to avoid data inconsistencies.
Secure Data Transfer
- Ensure that the data transfer is secure, especially if the data contains sensitive information.
- Use secure methods to transfer the CSV file and consider encrypting the file before transferring it.
By following these steps, you can move data from BigQuery to PostgreSQL without the need for third-party connectors or integrations. Remember to test the entire process with a small subset of data before attempting to transfer large volumes of data.
FAQs
What is ETL?
ETL, an acronym for Extract, Transform, Load, is a vital data integration process. It involves extracting data from diverse sources, transforming it into a usable format, and loading it into a database, data warehouse or data lake. This process enables meaningful data analysis, enhancing business intelligence.
BigQuery is a cloud-based data warehousing and analytics platform that allows users to store, manage, and analyze large amounts of data in real-time. It is a fully managed service that eliminates the need for users to manage their own infrastructure, and it offers a range of features such as SQL querying, machine learning, and data visualization. BigQuery is designed to handle petabyte-scale datasets and can be used for a variety of use cases, including business intelligence, data exploration, and predictive analytics. It is a powerful tool for organizations looking to gain insights from their data and make data-driven decisions.
BigQuery provides access to a wide range of data types, including:
1. Structured data: This includes data that is organized into tables with defined columns and data types, such as CSV, JSON, and Avro files.
2. Semi-structured data: This includes data that has some structure, but not necessarily a fixed schema, such as XML and JSON files.
3. Unstructured data: This includes data that has no predefined structure, such as text, images, and videos.
4. Time-series data: This includes data that is organized by time, such as stock prices, weather data, and sensor readings.
5. Geospatial data: This includes data that is related to geographic locations, such as maps, GPS coordinates, and spatial databases.
6. Machine learning data: This includes data that is used to train machine learning models, such as labeled datasets and feature vectors.
7. Streaming data: This includes data that is generated in real-time, such as social media feeds, IoT sensor data, and log files.
Overall, BigQuery's API provides access to a wide range of data types, making it a powerful tool for data analysis and machine learning.
What is ELT?
ELT, standing for Extract, Load, Transform, is a modern take on the traditional ETL data integration process. In ELT, data is first extracted from various sources, loaded directly into a data warehouse, and then transformed. This approach enhances data processing speed, analytical flexibility and autonomy.
Difference between ETL and ELT?
ETL and ELT are critical data integration strategies with key differences. ETL (Extract, Transform, Load) transforms data before loading, ideal for structured data. In contrast, ELT (Extract, Load, Transform) loads data before transformation, perfect for processing large, diverse data sets in modern data warehouses. ELT is becoming the new standard as it offers a lot more flexibility and autonomy to data analysts.
What should you do next?
Hope you enjoyed the reading. Here are the 3 ways we can help you in your data journey:
BigQuery is a cloud-based data warehousing and analytics platform that allows users to store, manage, and analyze large amounts of data in real-time. It is a fully managed service that eliminates the need for users to manage their own infrastructure, and it offers a range of features such as SQL querying, machine learning, and data visualization. BigQuery is designed to handle petabyte-scale datasets and can be used for a variety of use cases, including business intelligence, data exploration, and predictive analytics. It is a powerful tool for organizations looking to gain insights from their data and make data-driven decisions.
An object-relational database management system, PostgreSQL is able to handle a wide range of workloads, supports multiple standards, and is cross-platform, running on numerous operating systems including Microsoft Windows, Solaris, Linux, and FreeBSD. It is highly extensible, and supports more than 12 procedural languages, Spatial data support, Gin and GIST Indexes, and more. Many web, mobile, and analytics applications use PostgreSQL as the primary data warehouse or data store.

1. First, you need to have a Google Cloud Platform account and a project with BigQuery enabled.
2. Go to the Google Cloud Console and create a new service account with the necessary permissions to access your BigQuery data.
3. Download the JSON key file for the service account and keep it safe.
4. Open Airbyte and go to the Sources page.
5. Click on the "Create a new source" button and select "BigQuery" from the list of available sources.
6. Enter a name for your source and click on "Next".
7. In the "Connection Configuration" section, enter the following information:
- Project ID: the ID of your Google Cloud Platform project
- JSON Key: copy and paste the contents of the JSON key file you downloaded earlier
- Dataset: the name of the dataset you want to connect to
8. Click on "Test Connection" to make sure everything is working correctly.
9. If the test is successful, click on "Create Source" to save your configuration.
10. You can now use your BigQuery source connector to extract data from your dataset and load it into Airbyte for further processing.


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!
What should you do next?
Hope you enjoyed the reading. Here are the 3 ways we can help you in your data journey:
TL;DR
Data migration between different database systems is a common task in modern data engineering. This article explores how to efficiently export data from Google BigQuery to PostgreSQL using Airbyte, an open-source data integration platform. We'll cover the key steps and considerations for setting up this data pipeline, enabling seamless transfer between these two popular database systems.
This tutorial’s purpose is to show you how.
What is BigQuery?
BigQuery is a cloud-based data warehousing and analytics platform that allows users to store, manage, and analyze large amounts of data in real-time. It is a fully managed service that eliminates the need for users to manage their own infrastructure, and it offers a range of features such as SQL querying, machine learning, and data visualization. BigQuery is designed to handle petabyte-scale datasets and can be used for a variety of use cases, including business intelligence, data exploration, and predictive analytics. It is a powerful tool for organizations looking to gain insights from their data and make data-driven decisions.
What is PostgreSQL?
An object-relational database management system, PostgreSQL is able to handle a wide range of workloads, supports multiple standards, and is cross-platform, running on numerous operating systems including Microsoft Windows, Solaris, Linux, and FreeBSD. It is highly extensible, and supports more than 12 procedural languages, Spatial data support, Gin and GIST Indexes, and more. Many web, mobile, and analytics applications use PostgreSQL as the primary data warehouse or data store.
{{COMPONENT_CTA}}
Integrate BigQuery with Postgres destination in minutes
Try for free now
Prerequisites
- A BigQuery account to transfer your customer data automatically from.
- A Postgres destination account.
- 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 BigQuery and Postgres destination, for seamless data migration.
When using Airbyte to move data from BigQuery to Postgres destination, it extracts data from BigQuery using the source connector, converts it into a format Postgres destination can ingest using the provided schema, and then loads it into Postgres destination via the destination connector. This allows businesses to leverage their BigQuery data for advanced analytics and insights within Postgres destination, simplifying the ETL process and saving significant time and resources.
Step 1: Set up BigQuery as a source connector

1. First, you need to have a Google Cloud Platform account and a project with BigQuery enabled.
2. Go to the Google Cloud Console and create a new service account with the necessary permissions to access your BigQuery data.
3. Download the JSON key file for the service account and keep it safe.
4. Open Airbyte and go to the Sources page.
5. Click on the "Create a new source" button and select "BigQuery" from the list of available sources.
6. Enter a name for your source and click on "Next".
7. In the "Connection Configuration" section, enter the following information:
- Project ID: the ID of your Google Cloud Platform project
- JSON Key: copy and paste the contents of the JSON key file you downloaded earlier
- Dataset: the name of the dataset you want to connect to
8. Click on "Test Connection" to make sure everything is working correctly.
9. If the test is successful, click on "Create Source" to save your configuration.
10. You can now use your BigQuery source connector to extract data from your dataset and load it into Airbyte for further processing.
Step 2: Set up Postgres destination as a destination connector

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

Once you've successfully connected BigQuery as a data source and Postgres destination as a destination in Airbyte, you can set up a data pipeline between them with the following steps:
- Create a new connection: On the Airbyte dashboard, navigate to the 'Connections' tab and click the '+ New Connection' button.
- Choose your source: Select BigQuery from the dropdown list of your configured sources.
- Select your destination: Choose Postgres destination from the dropdown list of your configured destinations.
- 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.
- Select the data to sync: Choose the specific BigQuery objects you want to import data from towards Postgres destination. You can sync all data or select specific tables and fields.
- 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.
- Test your connection: Click the 'Test Connection' button to make sure that your setup works. If the connection test is successful, save your configuration.
- Start the sync: If the test passes, click 'Set Up Connection'. Airbyte will start moving data from BigQuery to Postgres destination according to your settings.
Remember, Airbyte keeps your data in sync at the frequency you determine, ensuring your Postgres destination data warehouse is always up-to-date with your BigQuery data.
Use cases for exporting data from BigQuery to PostgreSQL
1. Data integration
Combining BigQuery's vast data processing capabilities with PostgreSQL's robust transactional features. This allows organizations to leverage BigQuery for large-scale analytics and export results to PostgreSQL for operational use.
2. Local data access
Exporting subsets of data from BigQuery to a local PostgreSQL instance for faster query performance and reduced latency, especially for frequently accessed data.
3. Data archiving
Moving historical or less frequently accessed data from BigQuery to PostgreSQL for long-term storage, potentially reducing BigQuery costs while maintaining data accessibility.
Reasons why developers might consider moving from BigQuery to PostgreSQL
1. Cost Control
BigQuery's pricing model is based on data storage and query usage, which can become expensive for high-volume or frequent queries. PostgreSQL, being an open-source solution, often has more predictable costs, especially when self-hosted.
2. Data ownership
PostgreSQL can be hosted on-premises or on any cloud provider, giving organizations full control over their data and infrastructure. This is particularly important for companies with strict data governance policies or those wanting to avoid vendor lock-in.
3. Complex transactional workloads
BigQuery is designed for analytical workloads (OLAP) rather than transactional workloads (OLTP). PostgreSQL, with support for ACID (Atomicity, Consistency, Isolation, Durability) properties, is better suited for high-concurrency, row-level operations that are characteristic of transactional processing.
4. Flexibility and customization
PostgreSQL offers more flexibility in terms of schema design, indexing strategies, and query optimization. It also supports a wide range of extensions and custom functions, allowing for greater adaptability to specific use cases.
5. Lower latency for small-scale queries
For applications requiring fast response times on smaller datasets, PostgreSQL can offer lower latency compared to BigQuery, which is optimized for large-scale data processing.
6. Real-time data processing
PostgreSQL's support for triggers and stored procedures allows for real-time data processing and business logic implementation directly in the database.
Wrapping Up
To summarize, this tutorial has shown you how to:
- Configure a BigQuery account as an Airbyte data source connector.
- Configure Postgres destination as a data destination connector.
- Create an Airbyte data pipeline that will automatically be moving data directly from BigQuery to Postgres 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!
What should you do next?
Hope you enjoyed the reading. Here are the 3 ways we can help you in your data journey:
Ready to get started?
Frequently Asked Questions
BigQuery provides access to a wide range of data types, including:
1. Structured data: This includes data that is organized into tables with defined columns and data types, such as CSV, JSON, and Avro files.
2. Semi-structured data: This includes data that has some structure, but not necessarily a fixed schema, such as XML and JSON files.
3. Unstructured data: This includes data that has no predefined structure, such as text, images, and videos.
4. Time-series data: This includes data that is organized by time, such as stock prices, weather data, and sensor readings.
5. Geospatial data: This includes data that is related to geographic locations, such as maps, GPS coordinates, and spatial databases.
6. Machine learning data: This includes data that is used to train machine learning models, such as labeled datasets and feature vectors.
7. Streaming data: This includes data that is generated in real-time, such as social media feeds, IoT sensor data, and log files.
Overall, BigQuery's API provides access to a wide range of data types, making it a powerful tool for data analysis and machine learning.