Remove YesWare & ConvertKit email trackers from links in GMail
This script removes YesWare & ConvertKit email trackers from email links in GMail. When you receive an email with these tracking links, the sender can *track* if and when you clicked on the links they sent you, how many times, from what IP address, etc. You can read more about YesWare on their website, and ConvertKit also describes on their website how tracking can provide "stats on every email".
Both the YesWare and ConvertKit links contain a tracking identifier followed by the real address the link points to, so this script just rewrites these links to remove the tracker.
For example, the YesWare tracking links look something like https://t.yesware.com/123/456/789/company-website.com/about-us.html
If you click on such a link, YesWare will track your click, associate it with your email, and then send you to company-website.com/about-us.html
. This script simply rewrites the link to remove the tracking part, and leaves you with a regular link that no longer points to the tracking domain but to the real target instead. It works the same way for ConvertKit, the format is just different. If anyone is clever enough to send you a YesWare link tracked by ConvertKit, the script will also take care of it.
The code is commented and should be clear enough for people to understand what it does.