Back to Integrations
integrationGoogle Drive node
integrationGmail node

Google Drive and Gmail integration

Save yourself the work of writing custom integrations for Google Drive and Gmail and use n8n instead. Build adaptable and scalable Data & Storage, and Communication workflows that work with your technology stack. All within a building experience you will love.

How to connect Google Drive and Gmail

  • Step 1: Create a new workflow
  • Step 2: Add and configure nodes
  • Step 3: Connect
  • Step 4: Customize and extend your integration
  • Step 5: Test and activate your workflow

Step 1: Create a new workflow and add the first step

In n8n, click the "Add workflow" button in the Workflows tab to create a new workflow. Add the starting point – a trigger on when your workflow should run: an app event, a schedule, a webhook call, another workflow, an AI chat, or a manual trigger. Sometimes, the HTTP Request node might already serve as your starting point.

Google Drive and Gmail integration: Create a new workflow and add the first step

Step 2: Add and configure Google Drive and Gmail nodes

You can find Google Drive and Gmail in the nodes panel. Drag them onto your workflow canvas, selecting their actions. Click each node, choose a credential, and authenticate to grant n8n access. Configure Google Drive and Gmail nodes one by one: input data on the left, parameters in the middle, and output data on the right.

Google Drive and Gmail integration: Add and configure Google Drive and Gmail nodes

Step 3: Connect Google Drive and Gmail

A connection establishes a link between Google Drive and Gmail (or vice versa) to route data through the workflow. Data flows from the output of one node to the input of another. You can have single or multiple connections for each node.

Google Drive and Gmail integration: Connect Google Drive and Gmail

Step 4: Customize and extend your Google Drive and Gmail integration

Use n8n's core nodes such as If, Split Out, Merge, and others to transform and manipulate data. Write custom JavaScript or Python in the Code node and run it as a step in your workflow. Connect Google Drive and Gmail with any of n8n’s 1000+ integrations, and incorporate advanced AI logic into your workflows.

Google Drive and Gmail integration: Customize and extend your Google Drive and Gmail integration

Step 5: Test and activate your Google Drive and Gmail workflow

Save and run the workflow to see if everything works as expected. Based on your configuration, data should flow from Google Drive to Gmail or vice versa. Easily debug your workflow: you can check past executions to isolate and fix the mistake. Once you've tested everything, make sure to save your workflow and activate it.

Google Drive and Gmail integration: Test and activate your Google Drive and Gmail workflow

Effortless Email Management with AI-Powered Summarization & Review

How it Works

This workflow automates the handling of incoming emails, summarizes their content, generates appropriate responses using a retrieval-augmented generation (RAG) approach, and obtains approval or suggestions before sending replies. Below is an explanation of its functionality divided into two main sections:

Email Handling and Summarization:
The process begins with the Email Trigger (IMAP) node which listens for new emails in a specified inbox.
Once an email is received, the Markdown node converts its HTML content into plain text if necessary, followed by the Email Summarization Chain that uses AI to create a concise summary of up to 100 words.

Response Generation and Approval:
A Write email node generates a professional response based on the summarized content, ensuring brevity and professionalism while keeping within the word limit.
Before sending out any automated replies, the system sends these drafts via Gmail for human review and approval through the Gmail node configured with free-text response options. If approved, the finalized email is sent back to the original sender using the Send Email node; otherwise, it loops back for further edits or manual intervention.
Additionally, there's a Text Classifier node designed to categorize feedback from humans as either "Approved" or "Declined", guiding whether the email should proceed directly to being sent or require additional editing.

Set Up Steps

To replicate this workflow within your own n8n environment, follow these essential configuration steps:

Configuration:
Begin by setting up an n8n instance either locally or via cloud services offered directly from their official site.
Import the provided JSON configuration file into your workspace, making sure all required credentials such as IMAP, SMTP, OpenAI API keys, etc., are properly set up under Credentials since multiple nodes rely heavily on external integrations for functionalities like reading emails, generating summaries, crafting replies, and managing approvals.

Customization:
Adjust parameters according to specific business needs, including but not limited to adjusting the conditions used during conditional checks performed by nodes like Approve?.
Modify the template messages given to AI models so they align closely with organizational tone & style preferences while maintaining professionalism expected in business communications.
Ensure correct mappings between fields when appending data to external systems where records might need tracking post-interaction completion, such as Google Sheets or similar platforms.

Nodes used in this workflow

Popular Google Drive and Gmail workflows

+3

✨🔪 Advanced AI Powered Document Parsing & Text Extraction with Llama Parse

Description This workflow automates document processing using LlamaParse to extract and analyze text from various file formats. It intelligently processes documents, extracts structured data, and delivers actionable insights through multiple channels. How It Works Document Ingestion & Processing 📄 Monitors Gmail for incoming attachments or accepts documents via webhook Validates file formats against supported LlamaParse extensions Uploads documents to LlamaParse for advanced text extraction Stores original documents in Google Drive for reference Intelligent Document Analysis 🧠 Automatically classifies document types (invoices, reports, etc.) Extracts structured data using customized AI prompts Generates comprehensive document summaries with key insights Converts unstructured text into organized JSON data Invoice Processing Automation 💼 Extracts critical invoice details (dates, amounts, line items) Organizes financial data into structured formats Calculates tax breakdowns, subtotals, and payment information Maintains detailed records for accounting purposes Multi-Channel Delivery 📱 Saves extracted data to Google Sheets for tracking and analysis Sends concise summaries via Telegram for immediate review Creates searchable document archives in Google Drive Updates spreadsheets with structured financial information Setup Steps Configure API Credentials 🔑 Set up LlamaParse API connection Configure Gmail OAuth for email monitoring Set up Google Drive and Sheets integrations Add Telegram bot credentials for notifications Customize AI Processing ⚙️ Adjust document classification parameters Modify extraction templates for specific document types Fine-tune summary generation prompts Customize invoice data extraction schema Test and Deploy 🚀 Test with sample documents of various formats Verify data extraction accuracy Confirm notification delivery Monitor processing pipeline performance
+2

Invoices from Gmail to Drive and Google Sheets

Attachments Gmail to Drive and Google Sheets Description Automatically process invoice emails by saving attachments to Google Drive and extracting key invoice data to Google Sheets using AI. This workflow monitors your Gmail for unread emails with attachments, saves PDFs to a specified Google Drive folder, and uses OpenAI's GPT-4o to extract invoice details (date, description, amount) into a structured spreadsheet. Use cases Invoice Management**: Automatically organize and track invoices received via email Financial Record Keeping**: Maintain a structured database of all invoice information Document Organization**: Keep digital copies of invoices organized in Google Drive Automated Data Entry**: Eliminate manual data entry for invoice processing Resources Gmail account Google Drive account Google Sheets account OpenAI API key Setup instructions Prerequisites Active Gmail, Google Drive, and Google Sheets accounts OpenAI API key (GPT-4o model access) n8n instance with credentials manager Steps Gmail and Google Drive Setup: Connect your Gmail account in n8n credentials Connect your Google Drive account with appropriate permissions Create a destination folder in Google Drive for invoice storage Google Sheets Setup: Connect your Google Sheets account Create a spreadsheet with columns: Invoice date, Invoice Description, Total price, and Fichero Copy your spreadsheet ID for configuration OpenAI Setup: Add your OpenAI API key to n8n credentials Configure Email Filter: Update the email filter node to match your specific sender requirements Benefits Time Saving**: Eliminates manual downloading, filing, and data entry Accuracy**: AI-powered data extraction reduces human error Organization**: Consistent file naming and storage structure Searchability**: Creates a searchable database of all invoice information Automation**: Runs every minute to process new emails as they arrive Related templates Email Parser to CRM Document Processing Workflow Financial Data Automation
+7

Effortless Email Management with AI-Powered Summarization & Review

How it Works This workflow automates the handling of incoming emails, summarizes their content, generates appropriate responses using a retrieval-augmented generation (RAG) approach, and obtains approval or suggestions before sending replies. Below is an explanation of its functionality divided into two main sections: Email Handling and Summarization: The process begins with the Email Trigger (IMAP) node which listens for new emails in a specified inbox. Once an email is received, the Markdown node converts its HTML content into plain text if necessary, followed by the Email Summarization Chain that uses AI to create a concise summary of up to 100 words. Response Generation and Approval: A Write email node generates a professional response based on the summarized content, ensuring brevity and professionalism while keeping within the word limit. Before sending out any automated replies, the system sends these drafts via Gmail for human review and approval through the Gmail node configured with free-text response options. If approved, the finalized email is sent back to the original sender using the Send Email node; otherwise, it loops back for further edits or manual intervention. Additionally, there's a Text Classifier node designed to categorize feedback from humans as either "Approved" or "Declined", guiding whether the email should proceed directly to being sent or require additional editing. Set Up Steps To replicate this workflow within your own n8n environment, follow these essential configuration steps: Configuration: Begin by setting up an n8n instance either locally or via cloud services offered directly from their official site. Import the provided JSON configuration file into your workspace, making sure all required credentials such as IMAP, SMTP, OpenAI API keys, etc., are properly set up under Credentials since multiple nodes rely heavily on external integrations for functionalities like reading emails, generating summaries, crafting replies, and managing approvals. Customization: Adjust parameters according to specific business needs, including but not limited to adjusting the conditions used during conditional checks performed by nodes like Approve?. Modify the template messages given to AI models so they align closely with organizational tone & style preferences while maintaining professionalism expected in business communications. Ensure correct mappings between fields when appending data to external systems where records might need tracking post-interaction completion, such as Google Sheets or similar platforms.
+4

🤖🧑‍💻 AI Agent for Top n8n Creators Leaderboard Reporting

This n8n workflow is designed to automate the aggregation, processing, and reporting of community statistics related to n8n creators and workflows. Its primary purpose is to generate insightful reports that highlight top contributors, popular workflows, and key trends within the n8n ecosystem. Here's how it works and why it's important: How It Works Data Retrieval: The workflow fetches JSON data files from a GitHub repository containing statistics about creators and workflows. It uses HTTP requests to access these files dynamically based on pre-defined global variables. Data Processing: The data is parsed into separate streams for creators and workflows. It processes the data to identify key metrics such as unique weekly and monthly inserters/visitors. Ranking and Filtering: The workflow sorts creators by their weekly inserts and workflows by their popularity. It selects the top 10 creators and top 50 workflows for detailed analysis. Report Generation: Using AI tools like GPT-4 or Google Gemini, the workflow generates a Markdown report summarizing trends, contributors, and workflow statistics. The report includes tables with detailed metrics (e.g., unique visitors, inserters) and insights into why certain workflows are popular. Distribution: The report is saved locally or uploaded to Google Drive. It can also be shared via email or Telegram for broader accessibility. Automation: A schedule trigger ensures the workflow runs daily or as needed, keeping the reports up-to-date. Why It's Important Community Insights**: This workflow provides actionable insights into the n8n community by identifying impactful contributors and popular workflows. This fosters collaboration and innovation within the ecosystem. Time Efficiency**: By automating data collection, processing, and reporting, it saves significant time and effort for community managers or administrators. Recognition of Contributors**: Highlighting top creators encourages engagement and recognizes individuals driving value in the community. Trend Analysis**: The workflow helps uncover patterns in usage, enabling better decision-making for platform improvements or feature prioritization. Scalability**: With its modular design, this workflow can be easily adapted to include additional metrics or integrate with other tools.
+8

Personal Portfolio CV Rag Chatbot - with Conversation Store and Email Summary

Personal Portfolio CV Rag Chatbot - with Conversation Store and Email Summary Target Audience This template is perfect for: Individuals looking to create a working professional and interactive personal portfolio chatbot. Developers interested in integrating RAG Chatbot functionality with conversation storage. Description Create a stunning Personal Portfolio CV with integrated RAG Chatbot capabilities, including conversation storage and daily email summaries. 2.Features: Training: Setup Ingestion stage Upload your CV to Google Drive and let the Drive trigger updates to read your resume cv and convert it into your vector database (RAG purpose). Modify any parts as needed. Chat & Track: Use any frontend/backend interface to call the chat API and chat history API. Reporting Daily Chat Conversations: Receive daily automatic summaries of chat conversations. Data stored via NocoDB. 3.Setup Guide: Step-by-Step Instructions: Ensure all credentials are ready. Follow the notes provided. Ingestion: Upload your CV to Google Drive. The Drive triggers RAG update in your vector database. You can change the folder name, files and indexname of the vector database accordingly. Chat: Use any frontend/backend interface to call the chat API (refer to the notes for details) . [optional] Use any frontend/backend interface to call the update chat history API (refer to the notes for details). 3.Tracking Chat: Get daily automatic summaries of chat conversations.Format email conversations report as you like. You are ready to go!

🎦🚀 YouTube Video Comment Analysis Agent

🎦🚀 YouTube Video Comment Analysis Agent This n8n workflow is designed to help YouTube creators analyze video details and comments to generate a comprehensive and actionable report. The workflow provides insights into video performance, audience engagement, and viewer feedback, helping creators identify trends, interests, and opportunities for future content creation. ✨ Key Features Video Performance Analysis: Extracts metrics like views, likes, and comments to evaluate the video's success. Comment Sentiment Analysis: Determines the tone of comments (positive, neutral, or negative) to understand audience sentiment. Recurring Themes Detection: Identifies common topics or questions in comments to highlight viewer interests. Engagement Drivers: Pinpoints what aspects of the video resonated most with viewers. Actionable Recommendations: Offers strategies for creating follow-up content or improving future videos. Keyword Suggestions: Extracts frequently mentioned terms for better discoverability on YouTube. Collaboration Opportunities: Suggests potential partnerships based on viewer feedback or related channels. 🛠️ How to Use Set Up Workflow Variables: Add your GOOGLE_API_KEY and the VIDEO_ID of the YouTube video you want to analyze in the "Workflow Variables" node. Ensure your Google API key has access to the YouTube Data API. Run the Workflow: Trigger the workflow manually or through another workflow using the "Execute Workflow Trigger" node. The workflow will fetch video details and comments using pagination to ensure all data is captured. Generate Insights: The workflow processes video details and comments to create a detailed report with actionable insights. Outputs include sentiment analysis, engagement drivers, content opportunities, and audience profiling. View or Share Results: The report is converted into Markdown and can be emailed via Gmail or saved to Google Drive as a document. 🌟 Value from This Workflow Gain a deeper understanding of your audience's preferences and feedback. Identify trends and engagement drivers to replicate success in future videos. Discover new content opportunities based on viewer questions and suggestions. Improve discoverability by leveraging keyword suggestions extracted from comments. Build stronger connections with your audience by addressing their needs effectively.

Build your own Google Drive and Gmail integration

Create custom Google Drive and Gmail workflows by choosing triggers and actions. Nodes come with global operations and settings, as well as app-specific parameters that can be configured. You can also use the HTTP Request node to query data from any app or service with a REST API.

Google Drive supported actions

Copy
Create a copy of an existing file
Create From Text
Create a file from a provided text
Delete
Permanently delete a file
Download
Download a file
Move
Move a file to another folder
Share
Add sharing permissions to a file
Update
Update a file
Upload
Upload an existing file to Google Drive
Search
Search or list files and folders
Create
Create a folder
Delete
Permanently delete a folder
Share
Add sharing permissions to a folder
Create
Create a shared drive
Delete
Permanently delete a shared drive
Get
Get a shared drive
Get Many
Get the list of shared drives
Update
Update a shared drive

Gmail supported actions

Add Label
Delete
Get
Get Many
Mark as Read
Mark as Unread
Remove Label
Reply
Send
Send and Wait for Approval
Create
Delete
Get
Get Many
Create
Delete
Get
Get Many
Add Label
Delete
Get
Get Many
Remove Label
Reply
Trash
Untrash

FAQs

  • Can Google Drive connect with Gmail?

  • Can I use Google Drive’s API with n8n?

  • Can I use Gmail’s API with n8n?

  • Is n8n secure for integrating Google Drive and Gmail?

  • How to get started with Google Drive and Gmail integration in n8n.io?

Need help setting up your Google Drive and Gmail integration?

Discover our latest community's recommendations and join the discussions about Google Drive and Gmail integration.
jake chard
Jan Koch
hubschrauber
Jon
David O'Neil

Looking to integrate Google Drive and Gmail in your company?

Over 3000 companies switch to n8n every single week

Why use n8n to integrate Google Drive with Gmail

Build complex workflows, really fast

Build complex workflows, really fast

Handle branching, merging and iteration easily.
Pause your workflow to wait for external events.

Code when you need it, UI when you don't

Simple debugging

Your data is displayed alongside your settings, making edge cases easy to track down.

Use templates to get started fast

Use 1000+ workflow templates available from our core team and our community.

Reuse your work

Copy and paste, easily import and export workflows.

Implement complex processes faster with n8n

red iconyellow iconred iconyellow icon