10

Almost every link on social media (or actually, almost everywhere I'm afraid) has this utm_* evilness appended to the URL. This needs to stop, so I'm looking for an extension that automatically strips query string attributes based on a regex even in case of redirects.

I already have Clean Links and it works great for sanitizing direct links like this one, but not from links that redirect to nasty URLs like the ones used on social media sites, for example if a t.co link redirects to http://example.com/?utm=something, Clean Links won't have any effect.

4

My bad. It appears Clean Links has a redirect cleaner feature hidden in its preferences. Pretty sad to see that feature isn't more visible nor enabled by default.

In Firefox's addon manager (type about:addons in the URL bar), open Clean Link's preferences and tick the "Redirect watcher" and "HTTP observer" checkboxes :

screenshot

Note that you have to turn off and on Clean Links for the change to reflect using its toolbar button, restarting the browser apparently has no effect.

You may use this link to test the changes. It makes use of HTTPBin and redirects to httpbin.org/get with a bunch of UTM crap appended to the URL. If you don't see any of it in the "args": {} object of the response (and the URL bar flickered yellow), it means everything is working fine.

2

A more flexible option than Clean Links is the Redirector Firefox extension.

With Redirector, you can redirect anything to anywhere.

It even allows regex (regular expression) and wildcard matches.

It includes full backup and restore functionality for the rules you create.

The user interface is excellent, and it is very easy to use.

Highly Recommended

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy