User Agent Parser

Parse and analyze user agent strings to identify browser, OS, and device information.

Sample User Agents
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Safari/605.1.15
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0
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
Mozilla/5.0 (iPad; CPU OS 17_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Mobile/15E148 Safari/604.1
Mozilla/5.0 (Linux; Android 14; SM-S918B) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Mobile Safari/537.36
Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)
Mozilla/5.0 (compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm)

What Is a User Agent String?

A user agent string is a text identifier that browsers and HTTP clients send with every request in the User-Agent header. It tells the server what software is making the request — including the browser name and version, operating system, device type, and rendering engine. Servers use this information for content negotiation, analytics, and compatibility decisions.

User Agent String Components

ComponentDescriptionExample
BrowserName and version of the web browserChrome/120.0.6099.71
Rendering EngineThe layout engine used to render pagesAppleWebKit/537.36 (Blink)
Operating SystemThe OS and version of the deviceWindows NT 10.0; Win64; x64
Device TypeDesktop, mobile, tablet, or botMobile (identified by keywords)
Device ModelSpecific device model (primarily mobile)iPhone, SM-G998B (Samsung Galaxy)

Common Use Cases

  • Responsive Design Testing: Identify which browsers and devices are accessing your site to prioritize testing.
  • Analytics: Track browser and OS market share among your users to guide technology decisions.
  • Bot Detection: Identify web crawlers, scrapers, and automated tools by their user agent strings.
  • Content Negotiation: Serve different content formats based on browser capabilities.
  • Troubleshooting: Debug browser-specific rendering issues by identifying the exact browser version and engine.

Frequently Asked Questions

Can user agent strings be faked?

Yes. User agents can be easily spoofed by browsers, extensions, and HTTP clients. Never rely on user agent strings for security decisions. Use feature detection instead of user agent sniffing for browser capability checks.

What is Client Hints?

Client Hints is a modern alternative to user agent strings. Instead of one long string, the browser sends structured headers (Sec-CH-UA, Sec-CH-UA-Platform, etc.) that are more reliable and privacy-preserving. Chrome has already begun reducing user agent string detail.