User-Agent Parser - Detect OS, browser & device info
Analyze User-Agent strings to detect browser, OS, device type, and rendering engine offline and locally.
Parsed Result
What is a User-Agent?
A User-Agent is a text string that your browser sends to every website you visit. This string tells the website which browser you are using, its version, your operating system, and other system configuration details.
This is used by servers and web developers to optimize site layout, debug device-specific bugs, or analyze web traffic. This parser runs 100% locally in your browser and does not send your User-Agent data to any external server.
About this tool
The User-Agent parser decodes the long string your browser sends with every request and tells you the browser, version, OS, platform and device type. Useful for analysing traffic logs, debugging rendering issues on specific Chrome versions, or building an analytics dashboard. It also handles Client Hints (Sec-CH-UA-*), the modern, more structured successor to User-Agent. All parsing happens in the browser, no strings are sent onward.
How to use it
- Paste a User-Agent string, or click "Use mine" for your own.
- See decoded fields: browser, version, engine, OS and device.
- For Client Hints, paste the Sec-CH-UA headers for structured parsing.
- Copy the field values into your analytics schema.
Examples
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36Browser: Chrome 128
Engine: Blink
OS: Windows 10/11
Device: desktopMozilla/5.0 (iPhone; CPU iPhone OS 17_5 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.5 Mobile/15E148 Safari/604.1Browser: Mobile Safari 17.5
Engine: WebKit
OS: iOS 17.5
Device: iPhone (mobile)Common use cases
- Analyse log lines to identify specific Chrome or Safari versions.
- Debug bugs that only appear on certain OS/browser combos.
- Segment users in analytics tools.
- Block or throttle bots and crawlers by User-Agent.
- Write tests that simulate different clients.
Frequently asked questions
- Why do all browsers say "Mozilla/5.0"?
- Historical baggage. Netscape (Mozilla) dominated early, and servers checked for "Mozilla" before delivering frames and JavaScript. IE claimed to be "Mozilla-compatible", then Safari, Chrome and everyone else copied that. Today "Mozilla/5.0" is pure cosmetics and no server relies on it.
- What are Client Hints?
- Client Hints are a set of new HTTP headers (Sec-CH-UA-*) that replace the chaotic User-Agent with structured fields: Sec-CH-UA (browser), Sec-CH-UA-Platform (OS), Sec-CH-UA-Mobile (is this mobile?), etc. They are sent only when the server has opted in via Accept-CH. Privacy-friendly because less data is sent by default.
- Can I trust the User-Agent?
- No. Users can change it (dev tools), bots often forge it to look like Chrome, and User-Agent "freezing" in Chrome means version numbers can be generic. Never use User-Agent alone for security decisions, only for statistics and adaptations where inaccuracy is fine.
- What is "GREASE" in Sec-CH-UA?
- GREASE means "Generate Random Extensions And Sustain Extensibility". The browser inserts fake brands like "Not_A Brand" into the Sec-CH-UA list to force servers to handle unknown values correctly. This avoids the "everyone-calls-themselves-Mozilla" ossification that happened to User-Agent.
Technical background
The User-Agent string has no formal grammar. RFC 7231 §5.5.3 only says it "should" contain product name and version separated by slash, followed by parenthesised comments. In practice it is a historical collage: "Mozilla/5.0" for compatibility, then a parenthesis with the platform (Windows NT 10.0; Win64; x64), "AppleWebKit/537.36 (KHTML, like Gecko)" from the Safari heritage, "Chrome/128.0.0.0" for the real browser name, and "Safari/537.36" as a fingerprint of the WebKit fork. Parsing it needs regexes against known patterns plus a source list of known Chromium-based browsers (Edge, Opera, Brave, Vivaldi). The modern answer is User-Agent Client Hints: Chrome, Edge and Opera reduce the version portion of the UA (freezing the major version as 128.0.0.0) and encourage servers to fetch exact values via Sec-CH-UA, Sec-CH-UA-Full-Version-List, Sec-CH-UA-Platform, Sec-CH-UA-Platform-Version, Sec-CH-UA-Mobile, Sec-CH-UA-Arch, Sec-CH-UA-Bitness and Sec-CH-UA-Model. Our parser handles both and emits a normalised JSON object you can plug into analytics pipelines.