GMAIL N8N INTEGRATION: AUTOMATE GMAIL WITH N8N

Looking to automate Gmail with n8n? You’re in the right place. The Gmail n8n integration gives you access to 1 powerful trigger and 26 actions to build sophisticated email automation workflows without writing a single line of code.

With this integration, you can automatically monitor incoming emails, send personalized messages, organize your inbox with labels, manage drafts, and handle entire email threads programmatically. Whether you need to route customer inquiries to the right team, automatically archive processed emails, or build complex approval workflows, the Gmail n8n integration handles it all.

In this guide, you’ll discover exactly how to connect Gmail to n8n, explore every available trigger and action in detail, and learn practical use cases to transform your email management.

n8n Logo

n8n Gmail Workflow: demonstration of an automation connecting Gmail to other applications via n8n. This video illustrates how Gmail triggers and actions integrate into an n8n workflow to automate your processes without code.

WHY AUTOMATE GMAIL WITH N8N?

The Gmail n8n integration opens up 1 trigger and 26 actions that cover virtually every email operation you could need. From monitoring your inbox for new messages to managing labels, drafts, and entire conversation threads, this integration transforms Gmail from a manual inbox into an automated communication hub.

The benefits are immediate and tangible. Time savings become obvious when you stop manually sorting emails, applying labels, or forwarding messages to team members. Set up rules once, and n8n handles the repetitive work 24/7. Response time improves dramatically when incoming emails automatically trigger workflows—imagine a customer inquiry instantly creating a CRM record, notifying your sales team on Slack, and sending an acknowledgment email. Zero oversight means the Gmail trigger monitors your inbox continuously, ensuring no important message slips through the cracks, even outside business hours.

Concrete workflows you can build include: automatically labeling and forwarding invoices to your accounting software, creating support tickets from customer emails, sending personalized follow-ups based on email content, archiving processed conversations, and building approval workflows where stakeholders respond directly via email. Connect Gmail to over 400 applications in n8n’s ecosystem to create workflows limited only by your imagination.

List of Gmail actions and triggers available in n8n

HOW TO CONNECT GMAIL TO N8N?

Gmail credentials configuration in n8n

Basic configuration:

  1. Add the Gmail node: In your n8n workflow, search for “Gmail” and drag the node onto your canvas. Select whether you need the trigger or an action.
  2. Create new credentials: Click on the “Credential to connect with” dropdown and select “Create New.” This opens the OAuth configuration panel.
  3. Configure OAuth2: You’ll need to set up OAuth2 credentials in the Google Cloud Console. Create a project, enable the Gmail API, configure the OAuth consent screen, and generate OAuth client credentials (Client ID and Client Secret).
  4. Authorize the connection: Paste your Client ID and Client Secret into n8n, then click “Sign in with Google.” Select the Gmail account you want to connect and grant the requested permissions.
  5. Test the connection: Once authorized, n8n will confirm the connection. Your Gmail credentials are now saved and ready to use across all Gmail nodes in your workflows.

💡 TIP: When setting up OAuth in Google Cloud Console, make sure to add all required scopes for the actions you plan to use. If you only need to read emails, you can limit permissions accordingly. However, for full functionality including sending and label management, grant comprehensive Gmail access. Also, keep your OAuth credentials secure—treat them like passwords.

GMAIL TRIGGERS AVAILABLE IN N8N

Gmail Trigger

The Gmail Trigger is your workflow’s starting point for any email-based automation. It continuously monitors your Gmail inbox and fires your workflow whenever a new message arrives that matches your specified conditions. This is the foundation for building reactive email workflows—from simple notifications to complex multi-step processes.

Configuration parameters: Credential to connect with (required) to establish the connection, Poll Times to define how frequently n8n checks for new emails with a Mode dropdown for options like “Every Minute,” Event (required) to specify the type of event such as “Message Received,” Simplify (optional toggle) for a cleaner data structure, and Filters to narrow down which emails trigger your workflow by sender, subject line, labels, or other attributes.

Typical use cases: Automatically create CRM contacts when emails arrive from new addresses, route support requests to different Slack channels based on subject keywords, archive and label invoices then extract data for your accounting system, or trigger follow-up sequences when prospects reply to outreach campaigns.

When to use it: Deploy the Gmail Trigger whenever your workflow needs to react to incoming emails. It’s essential for customer service automation, lead management, document processing, and any scenario where email content should initiate downstream actions.

Gmail Trigger configuration for Gmail in n8n

NEED HELP AUTOMATING GMAIL WITH N8N?

We’ll get back to you in minutes ✔

GMAIL ACTIONS AVAILABLE IN N8N

Add label to message

The “Add label to message” action lets you programmatically organize your Gmail inbox by applying labels to specific emails. This is essential for building automated sorting systems that keep your inbox structured without manual intervention.

Key parameters: Credential to connect with (required dropdown), Message ID (required text input for the unique email identifier), and Label Names or IDs (required dropdown to select one or more labels to apply).

Use cases: Automatically label emails from VIP clients as “Priority,” tag invoices with “Accounting” for easy filtering, or mark processed support tickets with “Resolved” labels.

Add label to message action configuration for Gmail in n8n

Get many messages

This action retrieves multiple emails from your Gmail account in a single operation. It’s perfect for batch processing scenarios where you need to analyze, export, or manipulate groups of emails.

Key parameters: Credential to connect with (required), Return All (optional toggle to retrieve every matching email), Limit (required if Return All is disabled, default 50), Simplify (optional for cleaner output), and Filters to add criteria for fetching specific emails.

Use cases: Export all emails from a specific sender for compliance review, batch process unread messages older than 7 days, or aggregate email data for analytics dashboards.

Get many messages action configuration for Gmail in n8n

Get a message

Retrieve detailed information about a single specific email. Use this when you need the full content, headers, or metadata of a particular message for processing or display.

Key parameters: Credential to connect with (required), Message ID (required text input for the unique email identifier), and Simplify (optional toggle for streamlined output format).

Use cases: Fetch email content to extract specific data points, display full message details in a custom notification, or retrieve attachments for further processing.

Get a message action configuration for Gmail in n8n

Delete a message

Permanently remove an email from your Gmail account. Unlike trashing, deletion is irreversible—use this action carefully for cleanup workflows or compliance-driven purging.

Key parameters: Credential to connect with (required) and Message ID (required text input for the unique message identifier).

Use cases: Automatically delete spam that bypasses filters, purge sensitive emails after processing, or clean up test or automated notification emails.

Delete a message action configuration for Gmail in n8n

Mark a message as read

Update an email’s status to “read,” removing it from your unread count. This is useful for indicating that automated processes have handled a message.

Key parameters: Credential to connect with (required) and Message ID (required text input for the email’s unique identifier).

Use cases: Mark support tickets as read after creating a helpdesk entry, indicate processed invoices have been handled, or update status after extracting data from incoming emails.

Mark a message as read action configuration for Gmail in n8n

Mark a message as unread

Reverse the read status of an email, making it appear unread again. Useful for flagging messages that need human attention after automated review.

Key parameters: Credential to connect with (required) and Message ID (required text input for the target email’s identifier).

Use cases: Flag emails that failed automated processing for manual review, reset status for messages that need follow-up, or mark high-priority items for team attention.

Mark a message as unread action configuration for Gmail in n8n

Remove label from message

Detach one or more labels from a specific email. Essential for updating organization status as messages move through workflow stages.

Key parameters: Credential to connect with (required), Message ID (required for the email’s unique identifier), and Label Names or IDs (required, accepts multiple values to specify which labels to remove).

Use cases: Remove “Pending” label after processing is complete, clear temporary workflow labels after archiving, or update categorization when email status changes.

Remove label from message action configuration for Gmail in n8n

Reply to a message

Send a reply to an existing email, maintaining the conversation thread. Perfect for automated responses, acknowledgments, or follow-up sequences.

Key parameters: Credential to connect with (required), Message ID (required for the email you’re replying to), Email Type (required dropdown to choose “HTML” or “plain text”), Message (required text input for reply content), and Options for additional settings like CC, BCC, or attachments.

Use cases: Send automatic acknowledgments to support requests, reply with requested information from a database, or automated follow-ups in sales sequences.

Reply to a message action configuration for Gmail in n8n

Send message and wait for response

Send an email and pause the workflow until the recipient responds. This powerful action enables human-in-the-loop workflows with approval buttons directly in the email.

Key parameters: Credential to connect with (required), To (required recipient email address), Subject (optional email subject line), Message (required email body content), Response Type (required dropdown for expected response type such as “Approval”), and Approval Options (optional to define approval buttons and their values).

Use cases: Request manager approval for expense reports, get sign-off before publishing content, or collect yes/no decisions from stakeholders via email.

Send message and wait for response action configuration for Gmail in n8n

Send a message

Compose and send new emails directly from your workflow. The most frequently used Gmail action for notifications, outreach, and automated communications.

Key parameters: Credential to connect with (required), To (required recipient address), Subject (required email subject), Email Type (required dropdown for “HTML” or “Plain Text”), Message (required email body), and Options for additional fields like CC, BCC, attachments, and more.

Use cases: Send welcome emails to new customers, notify teams about completed workflows, or distribute automated reports and summaries.

Send a message action configuration for Gmail in n8n

Delete a label

Remove a label entirely from your Gmail account. Use this for cleanup or when label structures need reorganization.

Key parameters: Credential to connect with (required) and Label ID (required text input for the unique identifier of the label to delete).

Use cases: Clean up temporary project labels after completion, remove deprecated categorization labels, or automate label lifecycle management.

Delete a label action configuration for Gmail in n8n

Create a label

Programmatically create new labels in Gmail. Essential for dynamic organization systems that adapt to new categories or projects.

Key parameters: Credential to connect with (required dropdown), Name (required text input to define the name of the new label), and Options (optional for additional settings for label appearance).

Use cases: Create project-specific labels automatically, generate client labels when new accounts are added to your CRM, or build dynamic categorization systems.

Create a label action configuration for Gmail in n8n

Create a draft

Save an email as a draft without sending. Useful for preparing messages that need review or scheduling for later.

Key parameters: Credential to connect with (required), Subject (optional text input for draft subject line), Email Type (required dropdown for “Text” or “HTML”), Message (optional text input for draft content), and Options (optional for additional configuration).

Use cases: Prepare responses for human review before sending, queue emails for batch review and approval, or create templated drafts for manual customization.

Create a draft action configuration for Gmail in n8n

Get many labels

Retrieve a list of all labels in your Gmail account. Useful for building dynamic interfaces or auditing your organization structure.

Key parameters: Credential to connect with (required), Return All (optional toggle to get all labels without limits), and Limit (optional numeric input for maximum labels to return, default 50).

Use cases: Sync Gmail labels with external project management tools, audit label usage and organization, or build dynamic label selection interfaces.

Get many labels action configuration for Gmail in n8n

Get a label info

Fetch detailed information about a specific label, including its configuration and usage statistics.

Key parameters: Credential to connect with (required) and Label ID (required text input for the unique identifier of the target label).

Use cases: Check label configuration before applying, retrieve label statistics for reporting, or validate label existence before operations.

Get a label info action configuration for Gmail in n8n

Delete a draft

Permanently remove a saved draft from your Gmail account. Use this for cleanup or after drafts are no longer needed.

Key parameters: Credential to connect with (required) and Draft ID (required text input for the unique identifier of the draft to delete).

Use cases: Clean up rejected draft responses, remove outdated prepared emails, or automate draft lifecycle management.

Delete a draft action configuration for Gmail in n8n

Get many drafts

Retrieve multiple drafts from your Gmail account. Perfect for building review interfaces or batch processing saved drafts.

Key parameters: Credential to connect with (required), Return All (optional toggle to retrieve all drafts), Limit (optional numeric input for maximum drafts to return, default 50), and Options (optional for additional filtering).

Use cases: Build draft review dashboards, audit pending communications, or batch process and send approved drafts.

Get many drafts action configuration for Gmail in n8n

Get a draft

Retrieve a specific draft’s content and metadata. Use this to display drafts for review or to process individual saved emails.

Key parameters: Credential to connect with (required), Draft ID (required text input for the unique identifier of the draft), and Options (optional for additional retrieval options).

Use cases: Display draft content for approval workflows, extract draft data for processing, or preview emails before sending.

Get a draft action configuration for Gmail in n8n

Get a thread

Retrieve all messages within a specific email conversation thread. Essential for understanding full conversation context.

Key parameters: Credential to connect with (required), Thread ID (required text input for the unique identifier of the conversation thread), and Simplify (optional toggle for streamlined output).

Use cases: Analyze complete customer conversations, extract full support ticket histories, or review entire email chains for context.

Get a thread action configuration for Gmail in n8n

Get many threads

Fetch multiple email threads based on filters. Ideal for batch processing conversations or building inbox overview displays.

Key parameters: Credential to connect with (required), Return All (optional toggle to get all matching threads), Limit (optional numeric input for maximum threads to return, default 50), and Filters (optional criteria for selecting specific threads).

Use cases: Export customer conversation histories, batch analyze support interactions, or build thread-based email reports.

Get many threads action configuration for Gmail in n8n

Delete a thread

Permanently remove an entire email conversation from Gmail. All messages in the thread are deleted together.

Key parameters: Credential to connect with (required) and Thread ID (required text input for the conversation thread’s unique identifier).

Use cases: Delete completed support threads after resolution, remove spam conversation chains, or clean up automated notification threads.

Delete a thread action configuration for Gmail in n8n

Remove label from thread

Detach labels from an entire conversation thread at once, affecting all messages within.

Key parameters: Credential to connect with (required), Thread ID (required text input for the target thread’s identifier), and Label Names or IDs (required text input for labels to remove from the thread).

Use cases: Clear status labels after thread processing, update thread organization as conversations progress, or batch update conversation categorization.

Remove label from thread action configuration for Gmail in n8n

Trash a thread

Move an entire email conversation to the trash. Unlike deletion, trashed threads can be recovered within 30 days.

Key parameters: Credential to connect with (required) and Thread ID (required text input for the conversation to trash).

Use cases: Archive completed conversations safely, remove processed threads with recovery option, or clean up inbox while maintaining recoverability.

Trash a thread action configuration for Gmail in n8n

Reply to a message (Thread)

Send a reply within a specific email thread, maintaining conversation continuity. Requires both thread and message context.

Key parameters: Credential to connect with (required), Thread ID (required text input for the conversation thread), Message Snippet or ID (required text input for specific message context for the reply), Email Type (required dropdown for “Text” or “HTML”), and Message (required text input for reply content).

Use cases: Continue automated conversation sequences, reply to specific messages within long threads, or build context-aware response systems.

Reply to a message (Thread) action configuration for Gmail in n8n

Untrash a thread

Restore an email conversation from the trash back to your inbox. Perfect for recovering accidentally deleted threads.

Key parameters: Credential to connect with (required) and Thread ID (required text input for the trashed thread to restore).

Use cases: Recover incorrectly archived conversations, restore threads flagged for re-review, or undo automated trash operations.

Untrash a thread action configuration for Gmail in n8n

Add label to thread

Apply labels to an entire email conversation, organizing all messages within the thread simultaneously.

Key parameters: Credential to connect with (required), Thread ID (required text input for the target conversation thread), and Label Names or IDs (required text input for labels to apply to the thread).

Use cases: Organize customer conversations by status, tag support threads with priority labels, or categorize entire conversations for team routing.

Add label to thread action configuration for Gmail in n8n

NEED HELP AUTOMATING GMAIL WITH N8N?

We’ll get back to you in minutes ✔

FREQUENTLY ASKED QUESTIONS ABOUT GMAIL N8N INTEGRATION

Is the Gmail n8n integration free to use?

Yes, the Gmail integration itself is completely free within n8n. Both n8n's self-hosted version (free and open-source) and their cloud plans include full Gmail integration capabilities at no additional cost. However, you'll need a Gmail or Google Workspace account, and Google's API has usage quotas. For most automation use cases, the free Gmail API limits (typically 250 quota units per user per second) are more than sufficient. If you're running high-volume operations, you may need to implement rate limiting in your workflows or upgrade to Google Workspace for higher quotas.

The Gmail n8n integration gives you access to virtually all email data. You can retrieve and manipulate message content (body, subject, headers), metadata (sender, recipients, timestamps), attachments, labels, and thread information. The trigger captures incoming messages with all their data, and actions let you create, modify, and delete messages, drafts, labels, and threads. You can extract email content to populate databases, sync labels with project management tools, and use email metadata to route workflows. The "Simplify" option on many actions helps return cleaner data when you don't need full raw email details.

Initial setup typically takes 10-15 minutes, with most time spent configuring Google Cloud Console OAuth credentials. Once you've created your Google Cloud project, enabled the Gmail API, and set up OAuth consent, the actual n8n connection takes just a few clicks. After your first successful authorization, subsequent Gmail nodes in your workflows connect instantly using saved credentials. If you're using Google Workspace with admin access, setup is even faster. The investment pays off immediately—a workflow that replaces 30 minutes of daily email management recovers setup time within the first day.