🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

Gmail + OpenRouter: daily inbox digest, zero digging

Lisa Granqvist Partner Workflow Automation Expert

Your inbox is not the problem. The daily digging is. You scan, you flag, you promise yourself you’ll reply later, and somehow the important thread still gets buried by “quick” messages.

This is where Gmail digest automation pays off fast. Founders feel it when client threads go quiet. Marketing leads feel it when approvals hide in reply chains. And operators get stuck turning “FYI” emails into actual tasks.

This workflow pulls your last day of Gmail, has OpenRouter summarize what matters, then sends you one structured digest every morning. You’ll see how it works, what you need, and where teams usually trip up.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: Gmail + OpenRouter: daily inbox digest, zero digging

The Problem: You Start the Day Reacting to Email

Most people don’t lose time in one dramatic inbox moment. It’s the slow drip. Ten minutes skimming subjects. Another ten opening threads “just in case.” Then you realize three messages actually contain decisions, one contains a deadline, and two are quietly blocking someone else. By the time you’ve pieced it together, your morning focus is gone and you’re already behind. Worse, you’ll miss things that don’t look urgent, like a client question buried in a forwarded chain or a task hidden in a polite paragraph.

It adds up fast. Here’s where it usually breaks down.

  • You reread the same threads multiple times because there’s no clean summary to anchor you.
  • Action items get trapped in “I’ll handle this later” territory, which means follow-ups slip.
  • Manual inbox triage steals the best hour of the day, when you could be doing actual work.
  • You miss deadlines because they were mentioned once, casually, in the middle of a reply.

The Solution: A Daily AI Digest That Pulls Out Tasks and Deadlines

This n8n workflow runs automatically every morning at 7 AM and turns the last 24 hours of Gmail into one digest you can actually use. It first calculates the “prior date” window, then pulls your recent unread emails from Gmail and collects the useful parts (sender, subject, snippets). That bundle is handed to an AI agent built with LangChain, using OpenRouter as the chat engine. The agent doesn’t just paraphrase. It looks for themes, decisions, tasks, issues, and deadlines, then formats the output into a clean, structured summary. Finally, n8n sends that digest back to your inbox as a single email, so you start the day with priorities instead of noise.

The workflow starts on a schedule, not on your willpower. Gmail gathers the messages, the OpenRouter model summarizes them into a bullet-style report, and the final digest is delivered via Gmail. One email in. One email out.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you receive about 40 emails a day across client work, internal updates, and newsletters that slipped in. Manually triaging is usually 1 minute each for a quick scan plus another 10 minutes for the “wait, what did I miss?” second pass, so call it about 50 minutes most mornings. With this workflow, you spend maybe 2 minutes reading one digest email, then 5 minutes jumping into only the threads that have real actions. That’s roughly 40 minutes back on a normal day.

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • Gmail to fetch unread emails and send the digest.
  • OpenRouter to generate the AI summary via a GPT-class model.
  • OpenRouter API key (get it from your OpenRouter dashboard).

Skill level: Beginner. You’ll connect Gmail, paste an API key, and edit one or two fields like your recipient email.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

A daily schedule kicks things off. The workflow starts at 7 AM, so the digest is waiting when you sit down. If 7 AM isn’t your vibe, you can move it.

The date window is computed. A small code step calculates the prior 24 hours, which keeps the Gmail pull consistent (no guessing what “yesterday” means).

Gmail messages are retrieved and compiled. n8n pulls unread emails, then aggregates sender names, subjects, and snippets into a single bundle that an AI model can summarize cleanly.

OpenRouter summarizes and Gmail sends the digest. The LangChain agent extracts tasks, deadlines, issues, and key threads, formats it into a structured report, then the final email is dispatched to your inbox (or another address you choose).

You can easily modify the Gmail query to include filters like from:, subject:, or is:unread based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Scheduled Start Trigger

Set the schedule that kicks off the daily digest workflow.

  1. Add and open Scheduled Start Trigger.
  2. Set the schedule rule to run daily at 07:00 (the node is configured with triggerAtHour set to 7).
  3. Keep the default settings if you want the workflow to run once per day.

Step 2: Connect Gmail for Email Retrieval

Build the Gmail search query and fetch messages from the last 24 hours.

  1. Open Compute Prior Date and confirm the jsCode builds a query like [YOUR_EMAIL] after:YYYY/MM/DD. Replace [YOUR_EMAIL] with your actual email in the code.
  2. Open Retrieve Unread Emails and set Operation to getAll and Return All to true.
  3. Set the Gmail filter q to {{ $json.searchQuery }} so it uses the dynamic query from Compute Prior Date.
  4. Credential Required: Connect your Gmail credentials in Retrieve Unread Emails (this node currently has no credentials configured).

⚠️ Common Pitfall: If you forget to replace [YOUR_EMAIL] in Compute Prior Date, Gmail will return no results.

Step 3: Aggregate and Summarize with AI

Compile email data into a single payload and send it to the AI summarizer.

  1. Open Compile Message Data and set Include to specifiedFields with Fields To Include set to id, From, To, Subject, snippet,CC.
  2. Open Digest Summary Agent and set Text to {{ $json.data }}.
  3. Review the System Message in Digest Summary Agent to match your preferred output format.
  4. Open OpenRouter Chat Engine and set Model to openai/gpt-3.5-turbo.
  5. Credential Required: Connect your OpenRouter credentials in OpenRouter Chat Engine (this node currently has no credentials configured). The AI model is attached to Digest Summary Agent, so credentials must be added to OpenRouter Chat Engine, not the agent node.

Step 4: Configure the Digest Email Output

Send the AI-generated summary as a digest email.

  1. Open Dispatch Digest Email and set Send To to {{ $('Compile Message Data').item.json.data[1].To }}.
  2. Set Message to {{ $json.output }} to use the AI summary output.
  3. Set Subject to Summary Of Emails Last 24 Hours and Email Type to text.
  4. Credential Required: Connect your Gmail credentials in Dispatch Digest Email (this node currently has no credentials configured).

Consider replacing {{ $('Compile Message Data').item.json.data[1].To }} with a fixed address if you want all summaries sent to a single inbox.

Step 5: Test and Activate Your Workflow

Run a full test to confirm emails are retrieved, summarized, and sent.

  1. Click Execute Workflow and verify Retrieve Unread Emails returns items.
  2. Confirm Compile Message Data outputs a single aggregated data array.
  3. Check Digest Summary Agent for a structured summary in output, then verify Dispatch Digest Email sends the message.
  4. When everything succeeds, toggle the workflow to Active so Scheduled Start Trigger runs daily.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Gmail credentials can expire or need specific permissions. If things break, check your n8n Credentials panel and confirm the Gmail scope is still authorized.
  • OpenRouter can rate-limit or reject requests if your API key is wrong or your account has billing issues. If the AI step fails, verify the OpenRouter key and check your OpenRouter usage dashboard first.
  • The default AI prompt is fine, but it’s generic. Add your brand voice and your preferred format (for example, “Tasks first, then deadlines”) early or you will keep editing the digest.

Frequently Asked Questions

How long does it take to set up this Gmail digest automation automation?

About 20 minutes if your Gmail and OpenRouter accounts are ready.

Do I need coding skills to automate Gmail digest automation?

No. You’ll mostly connect accounts and paste an API key. The only “code” step is already included, and you typically just replace the placeholder email address.

Is n8n free to use for this Gmail digest automation workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in OpenRouter API usage, which is usually low for daily digests but depends on your model and email volume.

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I customize this Gmail digest automation workflow for a Slack or Telegram delivery instead of email?

Yes, but you’ll change the final “send” step. Keep the Gmail retrieval and the OpenRouter agent as-is, then swap the Dispatch Digest Email node for a Telegram send node (or Slack). Common tweaks include sending the “Tasks” section to a team channel, delivering the full digest to a private chat, and adding a subject filter so only project emails are summarized.

Why is my Gmail connection failing in this workflow?

Usually it’s expired authorization or missing Gmail permissions in n8n. Reconnect your Gmail credential, then confirm the workflow is allowed to read messages and send email. If your Gmail query is too strict (for example, only pulling unread plus extra filters), you may also be getting zero results, which can look like a failure downstream.

How many emails can this Gmail digest automation automation handle?

Practically, dozens per day is fine for most inboxes.

Is this Gmail digest automation automation better than using Zapier or Make?

Often, yes, if you care about control and cost once it’s running. n8n makes it easier to add logic like “only summarize unread,” store memory across runs, or reshape the email bundle before the AI sees it. You can also self-host, which matters if your digest becomes part of a larger internal system. Zapier and Make are still good for quick two-step zaps, but AI-heavy flows can get pricey when every message becomes a paid task. If you’re torn, Talk to an automation expert and describe your email volume and what you want the digest to include.

Once this is running, your inbox stops being a morning obstacle. You get one clear digest, then you decide what deserves your attention.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal