Automate Google Sheets & Drive with n8n: A Step-by-Step Guide
Learn how to automate your Google Sheets and Drive tasks using n8n. This tutorial covers setting up scheduled workflows, securely connecting to your Google accounts, and automating tasks like report generation and file syncing. Perfect for beginners and automation experts alike!

In this blog, we'll walk through setting up a simple yet powerful automation workflow in n8n. We'll cover:
- Using the Schedule Trigger to run tasks automatically
- Setting up credentials for Google Sheets
- Setting up credentials for Google Drive
Whether you're automating reports, syncing files, or updating sheets daily, these foundational steps will kickstart your no-code automation journey.
Easily deploy the n8n workflow automation tool in just a few clicks using Nife.io
Explore the step-by-step guide to deploy the n8n application and start automating your processes today.
Step 1: Adding the Schedule Trigger
- In your n8n workflow canvas, add the Schedule Trigger node.
- Configure it based on your desired frequency:
- For daily runs, select "Every Day" and set the time.
- For testing, you can choose "Every Minute" to observe immediate executions.
Why this is important:
The Schedule Trigger ensures your workflow runs automatically at set intervals without manual intervention.
Step 2: How to Acquire OAuth Client ID & Client Secret from Google Cloud
Before setting up credentials in n8n, you need your Client ID and Client Secret from Google Cloud Platform (GCP).
Step-by-Step Guide:
-
Go to Google Cloud Console
Visit console.cloud.google.com. -
Create a New Project (if needed)
- Click the project dropdown on the top bar.
- Click “New Project”, give it a name, and create it.
-
Enable the Required APIs
- From the left sidebar, go to APIs & Services → Library.
- Search for Google Sheets API and click Enable.
- Search for Google Drive API and click Enable.
-
Configure OAuth Consent Screen
- Go to APIs & Services → OAuth consent screen.
- Select External or Internal based on your account type.
- Fill in App Name, User Support Email, and Developer Contact Email.
- Under Scopes, add the following:
- For Google Sheets:
https://www.googleapis.com/auth/spreadsheets - For Google Drive:
https://www.googleapis.com/auth/drive
- For Google Sheets:
- Save and continue until completed.
-
Create OAuth Credentials
- Go to APIs & Services → Credentials.
- Click “+ Create Credentials” → select OAuth client ID.
- For Application type, choose:
- Desktop App (if testing locally) or
- Web Application (for production usage).
-
Add Authorized Redirect URI
- If using Web Application, under Authorized redirect URIs, add:
This allows n8n to complete the OAuth flow securely.https://api.n8n.io/oauth2/callback
- If using Web Application, under Authorized redirect URIs, add:
-
Save and Copy
- Once created, you will see your Client ID and Client Secret.
- Copy both and save them securely. You will use them when creating credentials in n8n.
Important:
Never share your Client Secret publicly. Treat it like a password to your app’s Google API access.
Why This Matters
Without proper Client ID and Secret setup, n8n cannot authenticate your Google account to read or write data. This step forms the backbone of all Google Sheets and Drive automations.
Step 3: Setting Up Google Sheets Credentials
-
In n8n, go to Credentials (from the left sidebar).
-
Click “New Credential” → choose Google Sheets API.
-
Provide:
- OAuth Client ID & Client Secret from your Google Cloud Console.
- The required Scopes, typically:
https://www.googleapis.com/auth/spreadsheets
-
Click Connect, authenticate with your Google account, and grant permissions.
Tip:
Ensure you have created OAuth credentials in Google Cloud with “Desktop App” or “Web Application” as the app type, and added:https://api.n8n.io/oauth2/callbackas your redirect URI.
Step 4: Setting Up Google Drive Credentials
-
Similarly, in Credentials, click “New Credential” → choose Google Drive API.
-
Use the same OAuth Client ID and Secret if you want both Sheets and Drive under the same project.
-
Select scopes such as:
https://www.googleapis.com/auth/drive https://www.googleapis.com/auth/drive.file -
Click Connect, authenticate, and grant permissions.
Note:
If you want to keep Sheets and Drive separate, you can create a new OAuth credential specifically for Google Drive.
Further Reading
For detailed guidance on setting up Google credentials in n8n, refer to the official documentation:
n8n Google Credentials Setup Guide
Conclusion
With the Schedule Trigger and Google credentials set up, you can now automate tasks like:
- Daily report generation in Google Sheets
- Syncing files between Google Drive and Sheets
- Archiving old files automatically This foundational setup opens the door to countless automation possibilities, saving you time and effort in managing your Google services.
Deploy on Nife
Ready to deploy? Check out the Nife documentation:
From the team at Nife
Deploy your next app in minutes, not days.
Nife is a multi-cloud edge platform that lets you deploy, scale, and manage applications globally without the infrastructure headache.