Skip to content
FunnelGuard

Fix guide by FunnelsGuard

Different redirects for mobile and desktop: how to find and fix

SEO-097Medium impactOther toolBy FunnelGuardPublished Updated
On this page

What this issue is

A device-based redirect sends a visitor somewhere different depending on whether their browser says it is a phone or a computer. A common example is example.com/product sending desktop users to the product page and mobile users to m.example.com or to the home page.

Some redirects are intended, such as an old separate mobile site. Many are accidents: a leftover plugin rule, a CDN setting, an old .htaccess block, or an app-banner script. The problem is that the two redirects often do not match, so one device ends on the wrong page, a slow chain, or a page that drops your tracking parameters.

Same link, two different journeys
  1. Ad or search clickLink to /product
  2. Device checkServer reads the user agent
  3. Mobile lands on home pageNot the product
  4. CheckoutNever reached on mobile

A mobile-only redirect sends phone visitors to the home page, so the product and checkout steps are lost for them.

Why it costs you leads or sales

Most web traffic is on phones, so a bad mobile redirect hits a large share of your visitors while the desktop version looks fine when you check it yourself.

What goes wrong
  • Mobile visitors land on the home page or an unrelated page instead of the one they clicked, so they leave.
  • Query strings such as gclid and UTMs can be lost in the mobile redirect, so ad clicks are not attributed.
  • Google indexes pages mainly with its smartphone crawler. If it is redirected somewhere odd, the page you want ranked may not be the one it sees.
  • Ranking signals can be split between example.com and m.example.com URLs.
  • Extra hops slow the first load on mobile networks.
  • Your own desktop tests pass, so nobody notices.
Product page visits that reach checkout, by deviceExample numbers
Product page visits that reach checkout, by device (example)Desktop: 6 %; Mobile (redirected to home): 1.5 %; Mobile (fixed): 4.5 %02561.54.5DesktopMobile (redirected to…Mobile (fixed)%

Example: illustrative numbers only. When mobile visitors are redirected to the home page, far fewer of them reach checkout than desktop visitors.

How to check if your site has it

Request the same URL twice, once with a desktop user agent and once with a mobile one, and compare where each ends up. Do this for your home page, top landing pages, product pages and any URL used in ads.

Compare desktop and mobile redirects with curlbash
# Desktop
curl -sIL -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36" "https://example.com/product?utm_source=test" | grep -iE "^(HTTP|location)"

# Mobile
curl -sIL -A "Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Mobile/15E148 Safari/604.1" "https://example.com/product?utm_source=test" | grep -iE "^(HTTP|location)"
Check in the browser too
  1. Open Chrome DevTools

    Press F12, then open the Network tab and tick Preserve log.

  2. Switch to device mode

    Click the device toolbar icon and choose a phone. This changes the user agent as well as the screen size.

  3. Load the URL and read the redirects

    Look for 301, 302 or 307 responses and the final URL. Repeat with device mode off and compare.

  4. Check Google Search Console

    Use URL Inspection, then Test Live URL, and compare the page Google fetched with the one you expect. Google's smartphone crawler is the default for most sites.

How to fix it

The best end state is one URL per page, served to all devices, with a responsive layout. Find where the device rule lives, remove or correct it, and add one clean 301 from any old mobile URLs to the matching desktop URL.

Where to look, by platform
  1. Check plugins

    Look at redirect, mobile and caching plugins (for example a mobile theme switcher or a cache plugin with a separate mobile cache). Turn off any device-based redirect.

  2. Check the theme

    Search the theme for wp_is_mobile() combined with wp_redirect. Remove the redirect and use CSS for layout differences.

  3. Check .htaccess

    Look for RewriteCond lines that test HTTP_USER_AGENT and delete them.

Example of a rule to remove (Apache)htaccess
# Remove rules like this one:
RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} "android|iphone|ipod|blackberry" [NC]
RewriteRule ^(.*)$ https://m.example.com/ [R=302,L]
If you must keep a separate mobile site
  1. Map every page one to one

    Each desktop URL must redirect mobile users to its equivalent mobile URL, never to the home page.

  2. Keep query strings

    Make sure gclid, utm_* and other parameters survive the redirect.

  3. Add annotations

    Put rel="alternate" media="only screen and (max-width: 640px)" on the desktop page and rel="canonical" on the mobile page, pointing at each other.

  4. Plan to retire it

    Moving to one responsive site is simpler and removes this class of bug.

Device-based redirect vs one URL

Before

  • Desktop stays on /product
  • Mobile is sent to the home page or an m. site
  • UTMs may be dropped on mobile
  • Google's smartphone crawler sees a different page

After

  • Every device stays on /product
  • Layout adapts with CSS
  • UTMs and gclid are kept
  • One URL collects all ranking signals
Try the device-based redirectInteractive
Mobile-only redirect rule

Rule active

Leads or data lost

Phones are sent to the home page, tracking parameters can be lost and the crawler sees a different page from desktop.

Toggle the rule to see how one user-agent condition changes where mobile visitors end up.

How to confirm it's fixed

Confirmation checks
  • Run the two curl commands again: both should end on the same final URL with the same status code.
  • Test with a UTM and a gclid on the URL and confirm they are still present at the end on mobile.
  • Open the page on a real phone, not only in DevTools.
  • Run Test Live URL in Search Console and check the fetched page and screenshot.
  • Check redirect counts: one hop at most, ideally none.
  • Clear CDN and page caches, then test again, since cached mobile variants can linger.

How to prevent it happening again

Prevention habits
  • Use a responsive design instead of separate mobile URLs.
  • Keep all redirect rules in one place and document who owns them.
  • After any plugin, theme, CDN or tag change, repeat the desktop and mobile test on your top landing pages.
  • Do not add geo, app-banner or popup scripts that change the page location without testing on mobile.
  • Crawl your site with a desktop and a mobile user agent in a crawler tool and compare the results regularly.

How FunnelGuard handles this

FunnelGuard does not check this yet. Comparing where the same URL redirects for desktop and mobile user agents is a possible future check, but it is not something the service does today.

What FunnelGuard does do is run your real customer journeys on a schedule, such as lead forms, checkouts, and booking and chat buttons, from the EU or the US. It checks each step and the tracking hits sent to platforms like GA4, Google Ads and Meta. If a redirect breaks one of those journeys, the failure is re-checked from a second region and you get one alert with a screenshot and a likely cause. That covers the journey the robot follows, not a comparison between device types.

To watch for this yourself, rerun the curl comparison above after every release, crawl your site with both a desktop and a smartphone user agent in a crawler tool, and review Search Console's page indexing and URL Inspection results for unexpected redirected pages. A free read-only website audit is also available from FunnelGuard, and the Free plan covers 1 site and 2 journeys with daily checks and no card.

Questions people ask

Why does my site redirect differently on mobile than on desktop?

Something is reading the user agent or screen width and sending phones elsewhere. Common sources are a mobile plugin, a theme function, an old .htaccess or Nginx rule, a CDN rule, or a script in a tag manager. Search those places for user agent checks.

Is it bad for SEO to redirect mobile users to a different URL?

It can be. Google mainly indexes with its smartphone crawler, so a wrong mobile redirect can change which page it sees. Separate mobile URLs also split ranking signals unless annotated correctly. One responsive URL for all devices is the simplest and safest setup.

How do I test a redirect with a mobile user agent?

Use curl with the -A option and a phone user agent string, or turn on device mode in Chrome DevTools. Compare the final URL and status codes against a desktop request. Test with a UTM parameter on the URL to see whether it survives.

Do I need an m. subdomain for my mobile site?

No. A responsive site that serves the same URL and HTML to all devices is the recommended approach. A separate m. site needs one-to-one page mapping, correct annotations and ongoing maintenance, so most sites are better off retiring it.

Why do my UTMs disappear only on mobile?

A mobile-specific redirect is probably dropping the query string. Fix the rule to pass parameters through, or better, remove the device redirect. Check with a test URL containing utm_source and gclid on a phone user agent.

Is redirecting based on user agent the same as cloaking?

Not always, but it is risky. Cloaking means showing search engines different content than users see. Redirecting phones to an equivalent mobile page is allowed, but sending crawlers and people to different destinations can break Google's policies, so keep it consistent.

Does FunnelGuard check for different mobile and desktop redirects?

Not yet. It is a possible future check. FunnelGuard currently runs your real customer journeys on a schedule and checks steps, tracking hits and lead delivery, so you should test device redirects manually or with a crawler for now.

Does FunnelGuard catch this?

Other tool

Needs a different kind of tool.

Stop finding out from your customers

FunnelGuard runs your real forms and checkouts on a schedule, checks the tracking and the leads behind them, and alerts you once, with a screenshot. Try any paid plan free for 3 days.