WebmasterID logoWebmasterID
User agents

User agent history and evolution

Modern user-agent strings are stuffed with historical tokens — Mozilla/5.0, AppleWebKit, KHTML, like Gecko, Safari — that no longer mean what they say. They accumulated as browsers copied each other's tokens to pass server-side sniffing. Understanding this history explains why today's strings are misleading and why feature detection and Client Hints are preferred.

Verified against primary sources

What this means

Almost every user agent begins with Mozilla/5.0, a relic of the 1990s when servers checked for Mozilla to decide whether to send frame-capable pages. Later browsers added the token so they would not be served a degraded experience. The pattern repeated: WebKit browsers carried like Gecko to satisfy Gecko sniffing, and Chrome carried Safari and AppleWebKit tokens to satisfy WebKit/Safari sniffing.

The result is strings that name several browser families the client is not actually running. The tokens are compatibility theatre, accumulated to avoid being mis-served by fragile detection.

Why it matters today

This history is the reason user-agent sniffing is fragile. A Chromium browser legitimately carries Mozilla, AppleWebKit, KHTML-style, Chrome, and Safari tokens at once. Matching the wrong one mislabels the client; matching too loosely catches unrelated browsers.

It is also why the platform is moving away from the monolithic string. User-agent reduction trims the cruft, and Client Hints expose specific, structured detail on request. For capability decisions, feature detection sidesteps the whole tangle.

How it appears in analytics and logs

Tokens like Mozilla, AppleWebKit, KHTML, and Safari in a user agent are largely legacy compatibility cruft, not literal statements about the browser. Their presence reflects history and sniffing-avoidance, not current identity.

Diagnostic use case

Understand why user-agent strings carry tokens from browsers the client is not, so you stop trusting them at face value and parse defensively.

What WebmasterID can help detect

Knowing the historical layering is why WebmasterID matches on stable, specific product tokens and treats the rest of the string as compatibility noise rather than fact.

Common mistakes

Privacy and accuracy notes

This is background context about string structure, not visitor data. WebmasterID uses the user agent only for coarse classification, informed by knowing these tokens are unreliable.

Frequently asked questions

Why does Chrome's user agent mention Safari and Mozilla?
Historical compatibility. Browsers copied each other's tokens so that servers sniffing for Mozilla, Gecko, or Safari would not serve a degraded page. The tokens persist as legacy cruft, which is why user-agent sniffing is unreliable.

Related pages

Sources and verification notes

Last reviewed 2026-06-24. Facts are checked against primary/official sources where available; uncertain specifics are marked “Data not yet verified” rather than guessed.