Discussion
  • Indexing
  • Technical SEO

Still running dynamic serving with Vary: User-Agent on a large site? Did caching or indexing problems eventually push you to a responsive build?

Published 1 reply

Discussion starter: a technical SEO question, posted with an answer from Niraj Raut to open the thread. If you have dealt with this on a site, reply with what you saw, especially where it differs.

Disclosure: Niraj Raut, who posted this answer, runs the SEO consultancy linked at the end of it.

1 reply

  • Niraj Raut
    Niraj Raut
    Original poster

    Dynamic serving still works, and Google still supports it, but most large sites that used it have moved to responsive design, and caching and parity problems are the usual reasons. Serving different HTML to mobile and desktop from the same URL requires a Vary: User-Agent header, which many CDNs handle poorly or normalise in ways that can serve the wrong version from cache. It also requires keeping two versions of every template in sync, and under mobile-first indexing, anything missing from the mobile version is effectively missing for Google. Google recommends responsive design as the simplest approach. If you are still on dynamic serving and cannot migrate soon, the priorities are content parity, correct caching and regular checks of what Googlebot receives.

    Common problems with dynamic serving

    Problem Effect
    CDN caching with Vary: User-Agent Cache fragmentation, or the wrong version served if the CDN normalises or ignores the header
    Content parity gaps Mobile version missing content, links or structured data; Google indexes the mobile version
    User-agent detection errors Tablets, new devices or crawlers get the wrong version
    Two codebases to maintain Changes shipped to one version and not the other
    Testing complexity Every release needs checking on both versions

    If you are still running it

    • Audit parity: compare mobile and desktop HTML for key templates, covering main content, headings, internal links, structured data, canonicals and robots directives.
    • Check caching: confirm how your CDN handles Vary: User-Agent, and whether it normalises user agents into device classes consistently.
    • Test as Googlebot: use URL Inspection to see the rendered page for key templates, since Google uses the smartphone crawler for indexing.
    • Add release checks that compare mobile and desktop output automatically.
    • Log device class by user agent so you can spot misdetection.

    Why responsive design is the usual endpoint

    Responsive design serves the same HTML to every device, with layout adapting through CSS. That removes caching complications, eliminates parity gaps by design, simplifies testing and halves template maintenance. Performance concerns that once favoured separate mobile HTML can usually be addressed with modern techniques such as responsive images, deferred loading of non-critical components and careful script management.

    Hypothetical example:

    A large retailer uses dynamic serving with a separate mobile template. After moving behind a new CDN, some mobile users receive desktop pages and vice versa, and an audit finds the mobile template lacks the “related categories” links and some structured data present on desktop. Because Google indexes the mobile version, those links and markup were effectively invisible to search. The retailer fixes the CDN configuration as a stop-gap, adds the missing elements to the mobile template, and schedules a move to a responsive design. After the move, parity problems disappear and category pages gain internal links that Google can now see.

    Watch for this:

    Moving from dynamic serving to responsive design changes the HTML Google sees on every page. Treat it as a significant release: compare the new responsive output with the current mobile version, since that is what Google has been indexing, and make sure nothing important is lost.

    Separate mobile URLs are a related case

    Some sites still use separate mobile URLs, such as an m. subdomain, rather than dynamic serving. They share many of the same problems, including parity gaps, duplicate maintenance and annotation requirements between the mobile and desktop versions, plus redirects and canonical relationships that can break. Google’s mobile-first indexing uses the mobile version, so gaps there matter. The same recommendation applies: move to responsive design when practical, and in the meantime audit parity and the annotations that connect the two versions.

    Planning the migration

    Because URLs usually stay the same when moving from dynamic serving to responsive design, the change is less risky than a URL migration, but it is still a template change on every page. Migrate template by template if possible, starting with lower-risk sections, and compare crawl data, rendered content and search performance after each step. Remove the Vary: User-Agent header once all templates are responsive, and simplify CDN caching rules accordingly.

    If you are still on dynamic serving, audit mobile and desktop parity, check caching behaviour, and test what Googlebot receives; then plan a move to responsive design, template by template, treating it as a significant release.

    Need help with this on your own site?

    Niraj Raut works with businesses in Nepal, Australia, the UK, Europe and the US on technical SEO, ecommerce SEO, local SEO and AI search.

    See SEO services

Add a reply

Replies are open to approved members. Log in or apply to join.