On this page
What this issue is
The browser keeps a list of pages a visitor has seen, called the history. Back moves one step down that list. The Back button is "broken" when that step does not take the visitor to where they came from.
There are three common forms of it:
| Pattern | What the visitor sees | Typical cause |
|---|---|---|
| Redirect loop on Back | Back lands on a URL that instantly sends them forward again | Server or JavaScript redirect on an intermediate URL (for example /go, /lang, a http to https or trailing slash rule) |
| History hijacking | Back keeps them on the same page, or needs many clicks | Script calls history.pushState repeatedly or re-adds an entry on popstate |
| Forced exit or popup | Back shows an offer or a different page instead of the previous one | Exit-offer or 'back button redirect' scripts, some ad or affiliate tools |
Why it costs you leads or sales
Visitors use Back to compare options, return to search results or correct a mistake. If it fails, they feel trapped and often close the tab. They may also lose trust in a checkout or form on the same site.
It is worst on paid traffic. You paid for the click, and the visitor cannot get back to the ad or search results to try another option, so they leave with a bad impression of your brand.
- Ad or search resultVisitor clicks through
- Short redirect URLRedirects to landing page
- Landing pageVisitor presses Back
- Redirect URL againSends visitor forward instantly
- Back to resultsNever reached
The visitor presses Back from the landing page and is sent forward again.
Example: illustrative numbers only. Of 100 visitors who press Back, the share who stay on the site.
How to check if your site has it
Test it as a visitor first, then look at the code. Use a private window so extensions and cached redirects do not hide the problem.
Start from a real entry point
Open Google results, an ad preview link or a campaign URL with UTM parameters. Click through to your landing page.
Press Back once
You should return to where you came from. If you stay on the page, reload, or jump forward, note the URL.
Repeat through the funnel
Go landing page, form, thank-you page and checkout, pressing Back at each step. Do it on mobile Safari and Chrome too, as behaviour differs.
Watch the history in DevTools
Open the Network tab, tick Preserve log, and press Back. Look for 301, 302 or 307 responses, or a document that loads twice.
Search the code for history calls
Search your theme, tag manager and scripts for
pushState,replaceState,popstate,location.replaceandlocation.href.
curl -sIL -o /dev/null -w '%{url_effective} %{num_redirects}\n' https://example.com/go
# More than 1 redirect, or a chain that returns to an earlier URL, is worth investigatingHow to fix it
The fix depends on the cause. A redirect that is meant to run once should replace the entry in history, not add one. A script that pushes history entries should be removed.
Identify the trapping URL or script
Use the Network log and code search from the check above. Note which URL redirects and which file calls the history API.
Remove history hijacking scripts
Delete any code that pushes a dummy entry on load or re-pushes on
popstate. Disable exit-offer or 'back redirect' tools in your plugins or tag manager.Make redirects server-side and single-hop
Use one 301 or 302 straight to the final URL. Avoid chains and avoid JavaScript redirects with
location.href, which add a history entry.Replace instead of push where a client redirect is needed
Use
location.replace(url)so the redirecting page is not left in history.Keep the Back-visible URL stable
Do not redirect visitors away from a URL they can reach with Back, such as language or country redirects that ignore their choice. Save the choice and respect it.
// Adds a history entry, so Back returns to the redirecting page and loops:
// window.location.href = 'https://example.com/landing';
// Replaces the current entry, so Back skips the redirecting page:
window.location.replace('https://example.com/landing');Check redirect plugins
Review Redirection, Rank Math or Yoast redirects and any language or geo plugin for rules that point back to the previous URL. Remove loops.
Disable popup and exit plugins
Deactivate popup, exit-intent and 'back button' plugins one by one, testing Back each time.
Check the https and www setting
Under Settings > General make sure the WordPress and Site Address URLs match the version your server and CDN redirect to.
Review URL redirects
Go to Content > Menus > View URL Redirects (or Online Store > Navigation > URL Redirects, depending on your admin). Remove redirects that point at each other.
Check apps
Disable apps that add popups, upsells or geo redirects, then retest. Also look in theme.liquid for
pushStatecode.
Audit Custom HTML tags
In your container, open Custom HTML tags and search for
pushState,popstateandlocation. Pause suspect tags in Preview mode and test Back.Check for redirect triggers
Look for tags that send visitors to another URL on page view or on exit.
Check 301 redirects
In Site settings > Hosting > 301 redirects, look for rules that send URLs to each other or to a URL that redirects back.
Check custom code
Review Site settings > Custom code and page-level code for history or redirect scripts.
Check funnel step redirects
In your funnel, review each step's settings and any custom domain path redirects so steps do not send visitors forward after Back.
Review custom code
Open funnel and step Tracking Code or custom code areas and remove scripts that use
pushStateor forced redirects.
Check redirects
In the Wix dashboard, open SEO > URL Redirect Manager and remove rules that loop.
Review custom code
Check Settings > Custom Code and Velo code for
wixLocation.tocalls on page load, which can trap Back.
Check URL mappings
Go to Settings > Developer Tools > URL Mappings and remove entries that point at each other.
Check code injection
Review Settings > Developer Tools > Code Injection for history or redirect scripts.
Fix server rules
Check .htaccess, nginx config and CDN rules for chained or circular redirects. Redirect each old URL directly to the final one.
Fix single-page app routing
In a JavaScript router, use replace navigation for redirects and do not call
pushStatefor the same route twice.
How to confirm it's fixed
- From a Google result or campaign link, Back returns to the source in one click
- From the landing page, form and thank-you page, Back goes to the previous step
- The Network log shows no repeated redirects after pressing Back
curl -sILshows one redirect at most for old URLs- Back works on desktop Chrome, mobile Safari and mobile Chrome
- Back works with and without a UTM-tagged URL
How to prevent it happening again
- Add a Back button test to your launch checklist for every new landing page and funnel
- Retest after installing or updating popup, redirect, language or A/B testing tools
- Review redirect rules whenever you change URLs, domains or https settings
- Ask for code review of any script that touches
historyorlocation - Keep a list of all redirects so you can spot loops
- Never use scripts that deliberately block Back
How FunnelGuard handles this
FunnelGuard does not check the Back button yet. It is a possible future check, so you cannot rely on FunnelGuard to tell you when history is hijacked or a redirect loops on Back.
What FunnelGuard does do is run your real customer journeys (lead forms, checkouts, booking and chat buttons) on a schedule from the EU or the US. It checks each step, the tracking hits sent to ad and analytics platforms, and whether test leads reach your inbox and CRM. A redirect loop on a forward step can make a journey fail, and that failure is re-checked from a second region before one alert goes out. But that is a broken forward journey, not a Back button test.
To watch for Back problems today, add the manual test above to your release routine and retest after plugin or redirect changes. You can also use browser DevTools or a site crawler to find redirect chains and loops. A free read-only website audit from FunnelGuard is available, and the Free plan covers 1 site and 2 journeys with daily checks and no card.
Questions people ask
Why is my website's back button not working?
Usually a redirect sends the visitor forward again, or a script adds extra entries to the browser history with history.pushState. Test in a private window, check the Network log for repeated redirects, and disable popup, exit-offer and redirect plugins one by one.
How do I fix a redirect loop when I press Back?
Find the URL that redirects and make it a single server-side redirect straight to the final page. If JavaScript does the redirect, use location.replace() instead of location.href so the redirecting page is not saved in history.
What is back button hijacking?
Back button hijacking is when a site manipulates the browser history so Back does not return the visitor to the previous page. It may keep them on the same page, send them elsewhere or show an offer. It is deceptive and should be removed.
Can a plugin break the Back button on WordPress or Shopify?
Yes. Popup, exit-intent, geo or language redirect, and A/B testing tools can add redirects or history entries. Disable them one at a time and test Back after each to find the culprit.
Why does Back take me to the same page again?
The page probably pushes a new history entry on load, or the previous URL redirects to the current one. Check for pushState calls and for a redirect on the URL before it in the Network log.
Does a broken back button hurt SEO?
It can. Visitors who cannot return to search results leave unhappy, and Google has said it treats back button hijacking as a spam practice. Check Google's current spam policies and remove any such scripts.
Does FunnelGuard monitor the Back button?
Not yet. It is a possible future check. FunnelGuard does run your key journeys on a schedule and checks each step, tracking hits and lead delivery, so a redirect problem that breaks a forward step may show up as a failed journey.
How do I test the Back button on mobile?
Open the site on a real phone in Safari and Chrome, start from a search result or ad link, and press Back at each funnel step. Mobile browsers handle history differently, so desktop testing alone can miss problems.
Related issues
- PRF-230Back button loses form/cart stateFix guide
- PRF-224Intrusive popup on entry before contentFix guide
- PRF-225Exit-intent popup fires on mobile scrollFix guide
- PRF-227Popup cannot be closedFix guide
- PRF-226Newsletter popup reappears on every pageFix guide
- PRF-208Main CTA not visible without scrollingFix guide