Bypass link shorteners and redirect pages
You click a link and instead of the destination you land on a "wait 5 seconds" page — a countdown, an ad, a "skip" button. Shorteners and redirect pages live off those seconds of your life. This rule jumps past them for you.
How redirect pages work
The intermediary page has the destination URL somewhere on it — in the "skip" link, in an attribute, in a JS variable or in a parameter of its own address. It reveals it only after a countdown, so it has time to show an ad. Since the URL is already there, there is no reason to wait.
The rule
The rule's JavaScript, URL pattern set to the specific shortener (or * — see pitfalls):
// 1. Destination in an address parameter (?url=... ?dest=...)
const here = new URL(location.href);
let jumped = false;
for (const key of ['url', 'dest', 'target', 'r', 'u']) {
const v = here.searchParams.get(key);
if (!jumped && v && /^https?:/.test(v)) {
location.replace(v);
jumped = true;
}
}
// 2. Destination in a visible "skip / continue" button
if (!jumped) {
const re = /continue|skip|get link|proceed/i;
const btn = [...document.querySelectorAll('a[href^="http"]')]
.find(a => re.test(a.textContent || ''));
if (btn) location.replace(btn.href);
}
How it works
Destination in a parameter
Many redirects look like redirect.com/go?url=https://target.... The rule reads parameters with common names and, if one looks like an http address, jumps there right away.
Destination in a button
When the URL is not in the address, we look for a visible link with "skip" / "continue" text pointing outward. location.replace (instead of href) does not leave the intermediary page in history — the back button works normally.
Pitfalls
- Set the URL pattern narrowly. A rule on
*may fire on a page that uses?url=for an entirely different purpose. Better to add one shortener at a time, the ones you actually use. - Some destinations are encoded. If the parameter is
%68%74%74%70..., adddecodeURIComponentbefore the check. - Affiliate links. By skipping the redirect you sometimes skip the commission of the creator you are heading to. Your choice — but worth knowing.
See also
- Examples — more ready-made JS rules
- Auto-pager — another click-saving rule
- URL patterns — how to target a rule precisely
Install JustZix — and reclaim those five seconds on every link.
Rate this post
No ratings yet — be the first.