Skip to main content

Summarize Gmail emails with Gemini and send an HTML action digest

Workflow preview

Workflow preview
100%
Summarize Gmail emails with Gemini and send an HTML action digest preview
Open on n8n.io

1. Workflow Overview

Who’s it for This template is for anyone who wants a quick, structured inbox review (founders, freelancers, support, operations) without reading every email. What it does Every 12 hours, the workfl...

Best for

  • Personal Productivity automation workflows
  • AI Summarization automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.noop, n8n-nodes-base.manualtrigger, n8n-nodes-base.scheduletrigger, n8n-nodes-base.datetime, n8n-nodes-base.gmail

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Mohammed Aljer.

Original n8n.io source

1.1 Workflow description

Title
Summarize Gmail emails with Gemini and send an HTML action digest
Workflow name
Summarize Gmail emails with Gemini and send an HTML action digest

Who’s it for

This template is for anyone who wants a quick, structured inbox review (founders, freelancers, support, operations) without reading every email.

What it does

Every 12 hours, the workflow checks Gmail for emails received in the last 12 hours, then summarizes each email and extracts the next action plus a priority level (high/normal/low). It generates a direct Gmail “Open message” link for each item (using rfc822msgid) and sends one clean HTML digest email. If there are no new emails, it sends a short “No new emails” message instead.

How to set up

  1. Connect your Gmail OAuth2 credentials in these nodes: Fetch Emails, Send Summary, No Emails.
  2. Connect your Gemini credentials in Google Gemini Chat Model.
  3. Update the recipient email in Send Summary and No Emails (sendTo), or replace it with a single variable in a Config/Set node.
  4. Click Test workflow once, then activate the workflow.

Requirements

  • Gmail account + Gmail OAuth2 credentials in n8n.
  • Google Gemini API access.

Recommended model

Use Gemini 2.5 Flash for fast, reliable structured output. If the model is not available in your region/account, select the closest available Gemini model.

How to customize the workflow

  • Change the lookback window (12 hours → 24 hours, etc.) by editing the Date/Time calculation.
  • Adjust the AI prompt rules (priority criteria, action wording, output fields).
  • Modify the HTML digest design to match your branding.
  • Remove or change the Inbox-only filter if you want to include other labels (Sent/Other).

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 2 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 3 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 4 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 5 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 6 - Sticky Note7

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 7 - Sticky Note8

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 8 - Google Gemini Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 9 - Structured Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 10 - No Operation, do nothing

Type / Role
n8n-nodes-base.noOp - noOp
Config choices
Version 1

Block 11 - No Operation, do nothing1

Type / Role
n8n-nodes-base.noOp - noOp
Config choices
Version 1

Block 12 - When clicking ‘Test workflow’

Type / Role
n8n-nodes-base.manualTrigger - manualTrigger
Config choices
Version 1

Block 13 - Run every 12 hours

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 14 - Compute receivedAfter (now - 12h)

Type / Role
n8n-nodes-base.dateTime - dateTime
Config choices
Version 2

Block 15 - Fetch Gmail emails (receivedAfter)

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 16 - Normalize email fields (From/To/snippet/messageId)

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 17 - Filter: Inbox only

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 18 - If: any emails found?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 19 - Build Gmail “Open message” link

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 20 - AI: extract summary, action, priority

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 21 - Merge: link + AI result

Type / Role
n8n-nodes-base.merge - merge
Config choices
Version 3.2

Block 22 - Aggregate: build digest list

Type / Role
n8n-nodes-base.aggregate - aggregate
Config choices
Version 1

Block 23 - Send HTML digest email

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 24 - Send “no new emails” email

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Showing the first 24 of 26 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Summarize Gmail emails with Gemini and send an HTML action digest
Complexity advanced
Nodes 26
Categories Personal Productivity, AI Summarization
Author Mohammed Aljer
Published 31 Jan 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/13126/13126.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Summarize Gmail emails with Gemini and send an HTML action digest do?

Who’s it for This template is for anyone who wants a quick, structured inbox review (founders, freelancers, support, operations) without reading every email. What it does Every 12 hours, the workfl...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Personal Productivity, AI Summarization use case.