SquareByteDigital Services

Knowledge base · Security

Open redirects: how scammers can borrow your website

Your website hasn’t been hacked. Your customer data is safe. Everything looks fine. Meanwhile, scammers could be using your web address, and the trust you’ve built, to send people wherever they like.

That’s an open redirect: a link that starts on your real website but bounces visitors somewhere else that someone else chose.

The short version: make sure nobody can edit one of your links to send visitors to any site they want. If your site has a redirect feature, it should only go to places you’ve approved.

How it works

Redirects are normal and useful. You rename a page, and the old address forwards to the new one. Someone signs in, and the site sends them back to where they were.

The trouble starts when the destination is written into the link itself and the site doesn’t check it. Something like:

https://yourbusiness.ca/go?url=https://scam.example

The link really does start at your website, so it looks trustworthy to people and to email filters. Then your site obligingly forwards the visitor to the scam page: a fake login, a fake invoice download, or worse.

Why it’s your problem too

We teach people to hover over links and check the domain. With an open redirect, the domain they see is genuinely yours. Microsoft has documented phishing campaigns that used real companies’ redirects exactly this way.

Nothing on your server changes, so it’s easy to shrug off. But if your name appears in a link that leads a customer into a scam, “the bad part happened on someone else’s website” won’t feel very reassuring. Over time, that can wear down the trust the scammers are borrowing. In some setups, an open redirect can also combine with other weaknesses to expose login information.

How to check your site

  • Look at your own links for things like ?url=, ?next=, ?redirect= or ?returnUrl=. Their presence doesn’t mean there’s a problem. The question is whether you can change what comes after the = to any website and have it work.
  • Try it yourself: replace the destination with a harmless outside site you know. If your site sends you there, it’s open.
  • Check sign-in pages, “continue to” links, link-tracking features in newsletters, and any add-ons that handle redirects.

How to fix it

Custom websites: the cleanest fix is a fixed list of allowed destinations. Instead of putting the full address in the link, use a short code that maps to an approved page. Internal redirects should only go to your own site. Your developer can follow OWASP’s guidance. Note that checking whether an address merely contains your domain isn’t enough.

WordPress: keep WordPress, plugins and themes updated, and review any plugin that handles redirects. Developers should use wp_safe_redirect(), which only allows approved sites.

Shopify, Wix and Squarespace: their built-in redirect managers, where you choose a fixed destination, are fine. Review apps, integrations and custom code instead. If one is the culprit, report it to its developer or the platform’s support, and turn it off if you don’t need it.

When someone reports an open redirect to you, thank them and take it seriously. It’s a good-faith tip, not an attack.

Checking for issues like this is part of a digital check-up, and every site I build only redirects to places it’s told to. See websites and look-alike domains for the other way scammers borrow your name.