User-Agent Parser
Parse any User-Agent string to detect browser, OS, device type, and rendering engine. Free, instant, and fully client-side.
Parse any User-Agent string to detect browser, OS, device type, and rendering engine. Free, instant, and fully client-side.
The User-Agent string is an HTTP header browsers and other clients send to identify themselves to servers. Originally a brief identifier, modern user agents are sprawling concatenations of historical version strings designed for backward compatibility with sites that sniff for specific browsers. A typical Chrome user agent today references Mozilla, AppleWebKit, KHTML, Gecko, Chrome, and Safari — most of which are vestigial.
Parsing a user agent extracts the actual browser, version, OS, and device type from this dense string. The data informs analytics, feature detection, and bot identification. It is also imperfect — user agents can be spoofed, misrepresent the actual browser engine, or fall behind reality (Chrome on iOS reports as Safari because all iOS browsers must use WebKit).
This parser uses pattern matching to identify common browsers, operating systems, and device categories from the user agent string. Output includes browser name and version, operating system and version, device type (desktop, mobile, tablet, bot), and rendering engine. Parsing happens in your browser; no data is sent anywhere.
Analytics, debugging, and security workflows all benefit from extracting structured data from raw user agent strings. Server logs containing millions of user agents become tractable when each is parsed into browser/OS/device fields. Bug reports listing user agents are easier to act on when you can quickly see what browser and version is involved.
Bot detection also relies on user agent parsing as a first signal. Many crawlers identify themselves honestly (Googlebot, Bingbot, GPTBot); others spoof Chrome but include subtle hints. Parsing helps surface these patterns.
Paste a user agent, see the structured data.
User-Agent parsing is fundamentally pattern-matching against a large library of regex rules. Browser detection uses substrings (Chrome, Firefox, Safari, Edge), OS detection looks for platform tokens (Windows NT 10.0, Mac OS X, Linux, Android, iPhone OS), and device detection combines OS with form-factor hints.
Order matters in parsing. Edge user agents include Chrome and Safari tokens, so checking for Edge must happen before Chrome. Brave, Vivaldi, and Opera all fork Chromium and have similar issues. Mature parsing libraries (ua-parser-js, ua-parser) maintain rule lists ordered for correct disambiguation.
User-Agent Client Hints (UA-CH) is the modern replacement: structured Sec-CH-UA headers replace the legacy User-Agent. Browsers are gradually freezing the legacy string and migrating to UA-CH. New parsing should support both.