I am building an app which is utilizing Sendgrid Marketing Email API, with the purpose of sending newsletters. It has a number of links to articles, but also banner ads and other service links. We would obviously like to keep tracking of article links, but exclude other links from affecting the click rate. Is it possible in any way to mark links which we don't wish to add to tracking?
4 Answers
Minor thread necromancy to let anyone who gets here via google know that they added an attribute to disable link tracking.
https://sendgrid.com/docs/Classroom/Track/Clicks/click_tracking_html_best_practices.html
Click tracking can be turned off for individual links by including the clicktracking=off attribute inside the anchor of an HTML link before the href. For example,
<a clicktracking=off href="http://example.com">link text</a>
would not be tracked.

- 1,763
- 17
- 28
The current click tracking application for SendGrid overwrites all links and there isn't, at this time, a way to customise this so only certain links are tracked.
One alternative would be to turn off the Click Tracking app in your SendGrid dashboard, but switch on the Google Analytics app (under Apps > Show Disabled Apps > Google Analytics).
With this app switched on, you can then build out custom links that you want to track using the Google Analytics URL Builder.
This would stop SendGrid rewriting all the URLs, and allow you to specify URLs that you want to track. However it would mean you will lose click event data in your SendGrid analytics, and via the Event Webhook, but the important data that you want to track for your campaigns would still be stored in Google Analytics.

- 1,493
- 9
- 12
-
2The SendGrid Click Tracker will only catch URLs that are fully properly formatted, with an ``. So, you can trick the Tracker into ignoring a link by dropping the quotes or `http://`, which will still work in pretty much every modern browser. – jacobmovingfwd Mar 05 '15 at 16:06
-
1@jacobmovingfwd Just tested removing the quotes and it still shows the masked url. Looks like sendgrid "fixed" this bug. Irked that almost every other email provider has some sort of tag to ignore tracking. – Myk Klemme May 10 '16 at 20:43
You can also disable Sendgrid's tracking using the api. To do this you set some email headers.
Example X-SMTPAPI header value:
{
"filters" : {
"clicktrack" : {
"settings" : {
"enable" : 0,
"enable_text" : false
}
}
}
}
This works for plain text emails.
See: https://sendgrid.com/docs/for-developers/sending-email/smtp-filters/#filter-clicktrack

- 36,864
- 16
- 117
- 117
1.To disable tracking for a specific link add clicktracking=off
before href
eg: <a clicktracking=off href="http://destination-domain.com">text</a>
2.To disable sendgrid link tracking for all mails
Goto Settings -> Tracking -> Click Tracking -> turn off link tracking

- 122
- 1
- 9