This email was sent automatically with n8n

Maybe the last email that the Gmail trigger fetched already contains the n8n text,

Try remove that email, unpin the pinned data in the Gmail trigger, and try again..

That’s all I can see from your screenshot…

i tried , and nothing changes .. and i evenreceived 2 mail now idk why ?
( the system normally cant do that ? the trigger have 1min of delay and i put a filter for unread emails only)


image

Hey @HFB,

If you have 2 unread emails in your inbox, the workflow will be triggered with 2 items.
Check in the execution history if 2 items were sent by the trigger.

Regarding the email footer…I don’t have any further recommendations beside backing up the workflows and setting up a new instance.

@HFB I ran into this same issue, and got it resolved. It’s a mouthful, but Claude helped fix it, and what was done. Hope this help.

Definitive fix for self-hosted n8n — Gmail “sent automatically with n8n” footer

The Append n8n Attribution toggle in the Gmail node options does not work reliably, especially for Gmail Tool nodes used in AI Agent/MCP workflows. Even when set to false, the footer
still appears.

Root cause (n8n v1.76+):

In GmailV2.node.js, the send operation has this logic:

let appendAttribution = options.appendAttribution;
if (appendAttribution === undefined) {
appendAttribution = nodeVersion >= 2.1; // defaults to TRUE when undefined
}

When Gmail is used as a Tool node (e.g., in AI Agent workflows), the options.appendAttribution value isn’t always passed through correctly, causing it to fall back to true for any node
version >= 2.1.

Additionally, the reply operation delegates to replyToEmail.js, which calls prepareEmailBody() without passing the appendAttribution flag at all — completely ignoring the user’s
setting.

Fix (self-hosted only):

  1. Find and copy out the file GenericFunctions.js from your n8n container:

Find the exact path (varies by n8n version)

docker exec n8n find /usr/local/lib/node_modules/n8n -name “GenericFunctions.js” -path “/Google/Gmail/”

Copy it out

docker cp n8n:<full_path>/GenericFunctions.js ./patches/GenericFunctions.js

  1. Edit ./patches/GenericFunctions.js — find the prepareEmailBody function (around line 302) and change:

if (appendAttribution) {
to:
if (false) {

  1. Mount the patched file into your container via compose.yml:

services:
n8n:
volumes:

  • ./patches/GenericFunctions.js:<full_path>/GenericFunctions.js:ro
  1. Restart: docker compose up -d
  2. Verify the patch is active:
    docker exec n8n grep “if (false)” <full_path>/GenericFunctions.js

Caveats:

  • This is a source patch, not an official setting — it will need to be re-applied if the internal package path changes after an n8n update.
  • The appendAttribution toggle in the UI/database is essentially broken for Tool nodes. This patch bypasses it entirely at the source level.

Tested on n8n v1.76+ with Gmail Tool nodes (n8n-nodes-base.gmailTool) in MCP/AI Agent workflows.