Introduction to data export

This document describes the different ways of exporting data from BigQuery.

For more information about data integrations, see Introduction to loading, transforming, and exporting data.

Export query results

You can export query results to a local file (either as a CSV or JSON file), Google Drive, or Google Sheets. For more information, see Export query results to a file.

Export tables

You can export your BigQuery tables in the following data formats:

Data format Supported compression types Supported export methods
CSV GZIP Export to Cloud Storage
JSON GZIP Export to Cloud Storage
Read from BigQuery using Dataflow
Avro DEFLATE, SNAPPY Export to Cloud Storage
Read from BigQuery using Dataflow
Parquet GZIP, SNAPPY, ZSTD Export to Cloud Storage

You can also export your BigQuery tables as Protobuf columns when working with nested data structures that require object type safety, or if you need a wider language support.

Large table export considerations

When exporting substantial data from BigQuery, consider the following:

  • Data volume and format:
    • Calculate the volume of data to be exported. Exports can incur substantial costs based on data size, format, method and geographic location. Some resources are charged per GiB, while others are charged per TiB.
    • Choose a format compatible with analysis tools and structure of your data. For example, CSV doesn't handle nested or repeated fields. Check data type compatibility.
    • Consider compression formats to reduce size and costs.
  • Export cost:
    • Some export methods are free up to a limit, while others always incur costs. For more information, see Data extraction pricing.
    • Costs can apply if your BigQuery table and destination, such as a Cloud Storage bucket, are in different locations.
  • Quotas: some export methods have daily limits. For more information, see Extract jobs.
  • Multiple files: large exports split into multiple files. Consider how you will manage these files downstream.
  • Automation: for recurring exports, use BigQuery scheduled queries or Dataflow.
  • Retention policies: determine retention periods in your destination dataset and implement lifecycle rules to optimize storage costs.
  • Security and access control: implement appropriate IAM permissions and encryption.

As you take these factors into consideration, we recommend performing a test export on a data subset to assess costs, file sizes, counts, and time. You can use a WHERE clause in your EXPORT DATA SQL statement to limit the test export.

Export BigQuery code assets

You can download BigQuery Studio code assets, such as saved queries or notebooks to maintain a local copy of your assets. For more information on downloading your BigQuery code assets, see the following:

Export using reverse ETL

You can set up reverse ETL (RETL) workflows to move data from BigQuery to the following databases:

What's next