Problem
Gmail “Send a message” node strips HTML links
With Email Type = HTML , the email still shows raw URLs instead of clickable hyperlinks.
What I tried
HTML directly in Message → links stripped
HTML built in a Set node (Email Body) and passed in with {{ $json["Email Body"] }} → links still stripped
Any idea how can I send email with hyperlink?
Hi,
In your workflow, keep using the Set node to create the email body. This is a good practice to keep things organized and easy to manage.
Set Node:
Name: Email Body
Value (Expression):
<p>Hello,</p>
<p>This is a test email with a hyperlink.</p>
<p>Please click <a href="https://n8n.io/">this link</a> to visit the n8n homepage.</p>
<p>Best regards,<br>Your automation system.</p>
In the Gmail “Send a message” node:
Set Email Type to HTML .
After that, a new field called HTML will appear. This is where you need to insert your HTML content.
Leave the Message field empty.
In the HTML field, use this expression:
{{ $json["Email Body"] }}
Hi Alex,
Thanks and when I did as you mentioned it work for your html but not with me.
This is what I am using:
{
“nodes”: [
{
“parameters”: {
“assignments”: {
“assignments”: [
{
“id”: “e77b2053-1c10-4b7e-ab5e-3f2202a5282d”,
“name”: “Email Body”,
“value”: “=Hi Team, \n\nPlease find the details of an endorsed lead below: \n\nProspect Details: \nName: {{ $node["Webhook"].json.body["Full Name"] }} \nTitle: {{ $node["Webhook"].json.body["Job Title"] }} \nCompany: {{ $node["Webhook"].json.body["Company Name"] }} \nLinkedIn Profile: \n\n {{ $node["Webhook"].json.body["LN Link"] }}\n \n\nCampaign Name: {{ $node["Webhook"].json.body["Campaign Name"] }} \n\nConversation Threads: \n‑ Dashboard: \n \n {{ $node["Update a task"].json.custom_fields[8].value }}\n \n‑ LinkedIn: \n \n {{ $node["Update a task"].json.custom_fields[20].value }}\n \n\nLet me know if any additional info is needed. \n\nBest regards, \n”,
“type”: “string”
}
]
},
“options”: {}
},
“type”: “n8n-nodes-base.set”,
“typeVersion”: 3.4,
“position”: [
2020,
-60
],
“id”: “e855ed3b-b532-4b34-8f63-ca88e1e415ca”,
“name”: “Edit Fields4”,
“executeOnce”: true
},
{
“parameters”: {
“sendTo”: “[email protected] ”,
“subject”: “test”,
“message”: “={{ $json[‘Email Body’] }}”,
“options”: {}
},
“type”: “n8n-nodes-base.gmail”,
“typeVersion”: 2.1,
“position”: [
2260,
-60
],
“id”: “35960475-03cd-41c3-b172-86b004c9bb41”,
“name”: “Send a message1”,
“webhookId”: “83e22597-b44c-42ef-942d-c3fbddf413fa”,
“credentials”: {
“gmailOAuth2”: {
“id”: “BqzPYbW6S4Ys4Fow”,
“name”: “BOT Gmail account”
}
}
}
],
“connections”: {
“Edit Fields4”: {
“main”: [
[
{
“node”: “Send a message1”,
“type”: “main”,
“index”: 0
}
]
]
}
},
“pinData”: {},
“meta”: {
“templateCredsSetupCompleted”: true,
“instanceId”: “1f4ccba3ce9c117ce59f62a29c3b414377336e3a8a224b2e116163fe92a1778b”
}
}
and this is what I get on email:
I added nodes not the HTML, here:
Hi Team,
Please find the details of an endorsed lead below:
Prospect Details:
Name: {{ $node[“Webhook”].json.body[“Full Name”] }}
Title: {{ $node[“Webhook”].json.body[“Job Title”] }}
Company: {{ $node[“Webhook”].json.body[“Company Name”] }}
LinkedIn Profile:
{{ $node[“Webhook”].json.body[“LN Link”] }}
Campaign Name: {{ $node[“Webhook”].json.body[“Campaign Name”] }}
Conversation Threads:
‑ Dashboard:
{{ $node[“Update a task”].json.custom_fields[8].value }}
‑ LinkedIn:
{{ $node[“Update a task”].json.custom_fields[20].value }}
Let me know if any additional info is needed.
Best regards,
I found the solution, I need to add fix text to hyperlink. It will not work if url and text both come from expression.
1 Like
system
Closed
August 12, 2025, 5:24am
6
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.