Integrate your Looker data directly into Google Sheets to streamline your operational workflows and ensure timely data access. The Looker Google Sheets action uses OAuth for authorization to send Looker content as CSV files. You can send this data once or on a recurring schedule.
Looker administrators can enable the Google Sheets action through the Looker Action Hub. Once enabled, users with appropriate permissions can select Google Sheets as a destination. This lets them send or schedule Looks and Explores, infusing data directly into their everyday business processes.
Things to know
There are several things to know about the Google Sheets action:
- Customer-hosted instances may be unable to enable actions from the Looker Action Hub, especially actions that support streamed results or that use OAuth, if the customer-hosted Looker instance does not fulfill the Looker Action Hub requirements. See the Sharing data through an action hub documentation page for suggested solutions to this potential issue.
- You can't schedule or send dashboards to Google Sheets. Dashboards require formats that support multiple tiles or archives (such as PDF, PNG, or ZIP), but the Google Sheets action only supports streaming a single query's results in plain CSV format. To deliver data to Google Sheets, schedule the delivery from the Look or Explore UI instead, and ensure that the output format is set to plain CSV.
- Google Sheets are limited to 10 million cells for the entire Sheet. If your data table has columns, rows, or tabs that exceed this limit, any deliveries to the Google Sheets integration will fail.
Enabling the Google Sheets action in Looker
Looker admins can enable the Google Sheets action in Looker with the following steps:
- Go to the Admin panel and, under Platform, go to the Actions page.
- On the list of Action Hub actions, scroll to Google Sheets and click the Enable button.
- On the Google Sheets action page, click the Enabled toggle to the on position, and click Save.
- When you return to the list of Action Hub actions, your Google Sheets action should be enabled.
Any users with the send_to_integration permission can now send or schedule
Looks or Explores in CSV format to a Google Sheet.
Delivering data in CSV format to a Google Sheet
Any Looker user who has send_to_integration permissions can
send or schedule Looks or Explores in CSV format to a Google Sheet.
To prepare your data before sending or scheduling it, follow these steps:
- Horizontal scaling: If your data table contains more than 26 columns and you plan to import the data to an existing Google Sheet, you'll need to manually expand the Google Sheet before you can import your data into it.
- Vertical scaling: If your data table contains more than 1,000 rows, Looker will add those rows to your Google Sheet by default.
- Overwriting: If you're going to import your data into an existing Google Sheet, write any formulas on a separate tab of your Google Sheet to preserve the logic in your formulas. If you use the Google Sheets action's overwrite function, the action dynamically updates your Google Sheet, and your data will automatically be loaded into the first or leftmost tab of your Google Sheet. If you'd prefer to create a new spreadsheet with each data delivery so that you have a full history of your data and can track changes over time, don't use the Google Sheets action's overwrite function.
To send or schedule your content, follow these steps:
- From the Scheduler, next to Where should this data go?, select Google Sheets as your delivery destination.
- If you're delivering to Google Drive for the first time, you'll need to authenticate with your Google credentials. Click Sign in with Google, specify your Google Account, and then click Allow to connect your Looker account to your Google OAuth credentials. You can connect only one set of Google OAuth 2.0 credentials to this integration.
- In the Scheduler, click Verify credentials to load your Google Drive.
From the Select Drive to save file drop-down, choose the Google Drive where your CSV file will be saved.
Next, you can either enter the URL for a folder in this Drive or fetch all folders in your Drive.
- In the Google Drive Destination URL field, enter the full Google Drive
URL of the folder where you want to save your data. For example:
https://drive.google.com/corp/drive/folders/abcxyz. If this URL isn't accessible, your data will be saved to the root folder of your Google Drive. - From the Select Fetch to fetch a list of folders in this drive drop-down, select Fetch. After the Scheduler dialog refreshes, from the Select folder to save file drop-down, select the Google Drive folder where your CSV file will be saved.
- In the Google Drive Destination URL field, enter the full Google Drive
URL of the folder where you want to save your data. For example:
Specify the name of your Google Sheet file in the Enter a filename field. You don't need to include the file extension — the Google Sheets action will automatically append it during delivery.
In the Overwrite Existing Files drop-down, select Yes or No. Selecting No will generate a new Google Sheet with a snapshot of your data with every data delivery. Selecting Yes will load your data in the first or leftmost tab of your existing Google Sheet.
Advanced options for CSVs include customizable limit and format. Click Send or Schedule.
Refresh your Google Drive folder to see your file delivery.
Switching Google Accounts
To associate a different Google Account with this action, you must delete the account's connection to the Looker instance. To learn more, see Manage connections between your Google Account and third-parties.