If you are using Email Trigger to access gmail, please consider using dedicated GMAIL triggers, and for this just refresh your credentials and make sure they are listening to new emails, let me know what works.
You are using JavaScript’s toLocaleString() to generate a date for the IMAP SINCE query.
Invalid Format: IMAP servers are extremely strict. They require dates in the format DD-Mon-YYYY (e.g., 09-Feb-2026). Your code sends something like 9/2/2026 15:30:00 (depending on the Spanish locale), which causes the IMAP server to reject the command or drop the connection after a few attempts.
Granularity: The IMAP SINCE command only supports Dates, not Times. You cannot ask the server for “emails from the last 2 minutes” using standard IMAP queries; you can only ask for “emails since today.”
The Solution:
You should rely on the UNSEEN flag and n8n’s internal tracking (if using the Trigger node) or simply fetch unread emails and process them.
Step 1: Fix the Custom Config
Open your Email Trigger (IMAP) node and change the Custom Email Config to just this:
["UNSEEN"]
Why?
This forces the node to only pick up emails marked as “Unread”.
It removes the broken date logic that is crashing the connection.
If you absolutely need the SINCE filter (e.g., to ignore old unread emails), use this valid n8n expression instead:
I noticed in your JSON that the node type is n8n-nodes-base.emailReadImap.
If you want this to run automatically: You must use the node explicitly named IMAP Trigger (the green trigger node).
If you are using the “Read Email” node: This node is an Action. It does not run by itself. You would need to add a Schedule Trigger node before it (e.g., set to run every 1 minute) to make it check for emails repeatedly.
If you are using the actual IMAP Trigger node and the JSON just looks weird, Step 1 (fixing the date format) is the solution.