[null,null,["最后更新时间 (UTC):2025-07-25。"],[[["\u003cp\u003eBigQuery, Google's petabyte-scale data warehousing solution, seamlessly integrates with Looker Studio for data analysis and visualization.\u003c/p\u003e\n"],["\u003cp\u003eLooker Studio offers a native BigQuery connector and the option to develop custom Community Connectors for bringing in BigQuery data.\u003c/p\u003e\n"],["\u003cp\u003eCommunity Connectors provide advantages like pre-built queries, centralized billing via service accounts, and custom caching options.\u003c/p\u003e\n"],["\u003cp\u003eFor basic data visualization needs, the native BigQuery connector within Looker Studio UI is often sufficient, while Community Connectors cater to more complex requirements and advanced functionalities.\u003c/p\u003e\n"]]],[],null,["# Connect to BigQuery\n\n[BigQuery](https://cloud.google.com/bigquery/) is Google's petabyte scale data warehousing solution. Looker Studio\nnatively integrates with BigQuery and can be used to analyze and visualize\nBigQuery data.\n\nImplementation steps\n--------------------\n\nThere are multiple ways to bring your BigQuery data into Looker Studio:\n\n- Using the native BigQuery connector in the Looker Studio UI\n- Developing and using a Community Connector\n\nUsing the native BigQuery connector in the Looker Studio UI\n-----------------------------------------------------------\n\nUsers can use the native [BigQuery connector](https://support.google.com/looker-studio/answer/6370296) in\nLooker Studio to visualize BigQuery tables or specific queries. You can fetch\nentire tables or run custom queries on BigQuery from within Looker Studio. It is\nalso possible to use the Looker Studio [Explorer](https://support.google.com/looker-studio/answer/9005651) feature to complete\nexploratory analysis of your BigQuery data.\n\nThis approach is helpful if your users:\n\n- are doing exploratory analysis.\n- are familiar with SQL and can write their own queries.\n- are familiar with the data and know how to visualize it from scratch.\n\n| **Note:** Your users will need a BigQuery billing account to use the native BigQuery connector in Looker Studio UI.\n\n### Example: Querying birth-rate data from BigQuery\n\n[This guide](https://cloud.google.com/bigquery/docs/visualize-looker-studio) shows how an\nend-user can use Looker Studio's native BigQuery connector from the Looker\nStudio UI to visualize BigQuery data. This example queries the BigQuery\n[natality](https://console.cloud.google.com/bigquery?p=bigquery-public-data&d=samples&t=natality&page=table&_ga=2.78047700.-1928147037.1539021163) sample table and fetches the entire table into Looker Studio.\n\n### Example: Building a BI dashboard with BigQuery, App Engine, and Looker Studio\n\n[How to build a BI dashboard using Looker Studio and BigQuery](https://cloud.google.com/blog/products/gcp/how-to-build-a-bi-dashboard-using-google-data-studio-and-bigquery) shows how you can\nuse App Engine to pre-aggregate BigQuery data and then visualize it with Looker\nStudio.\n\nDeveloping and using a Community Connector\n------------------------------------------\n\nYou can develop a [Community Connector](/looker-studio/connector) that fetches data from BigQuery. This\napproach gives you benefits over using the native connector:\n\n1. You can incorporate existing queries into your Connector. Your users won't have to write their own SQL or copy/paste SQL snippets to get the exact query. Additionally, you can parameterize your queries and let your users provide input via the connector configuration to customize the queries.\n2. You can use service accounts to centralize billing. Your users will not need access to a GCP billing account.\n3. Your users can start with ready made template reports with their own data.\n4. You can implemented your own caching layer to control BigQuery cost.\n\nIn a Community Connector, you can access BigQuery data in three separate ways:\n\n- [Looker Studio Advanced Services](/looker-studio/connector/advanced-services)\n- [Apps Script BigQuery Service](/apps-script/advanced/bigquery)\n- [BigQuery REST API](https://cloud.google.com/bigquery/docs/reference/rest/v2/)\n\nThis table summarizes the pros and cons:\n\n| | Looker Studio Advanced Services | Apps Script BigQuery Service | BigQuery REST API |\n|-------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------|\n| Reference | [Looker Studio Advanced Services](/looker-studio/connector/advanced-services) | [Apps Script BigQuery Service](/apps-script/advanced/bigquery) | [BigQuery REST API](https://cloud.google.com/bigquery/docs/reference/rest/v2/) |\n| Flow of data | BigQuery \\\u003e Looker Studio | BigQuery \\\u003e Apps Script \\\u003e Looker Studio | BigQuery \\\u003e Apps Script \\\u003e Looker Studio |\n| Calculated fields supported via `getschema` | Yes | Yes | Yes |\n| Can be used with a service account/custom access control | Yes | No (effective user's credentials enforced) | Yes |\n| Filters are automatically pushed down | Yes | No | No |\n| Additional data transformation needed in `getData` | No | Yes | Yes |\n| Fetched data can be accessed in Apps Script (Lets you do additional transformation) | No | Yes | Yes |\n| Custom caching supported | No | Yes | Yes |\n| [UrlfetchApp Quota](/apps-script/guides/services/quotas) applied | No | No | Yes |\n| Example implementation | [World Bank data connector](https://github.com/googledatastudio/community-connectors/tree/master/world-bank/src) | [Apps Script BigQuery Service](/apps-script/advanced/bigquery) | [Chrome UX Connector](https://github.com/googledatastudio/community-connectors/tree/master/chrome-ux-report) |\n\nUnless you need to transform the fetched data from BigQuery or need custom\ncaching, in most use cases, you can use *Looker Studio Advanced Services*."]]