Is it possible to exclude links from tracking

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.


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


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.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