Skip to content

User Agent Parser

Parse a User-Agent string into browser and OS.

Input
Output

No result

About User Agent Parser

User Agent Parser reads the identification string a browser sends with every request and extracts three things that are useful when triaging a bug report: which browser and version it appears to be, which operating system, and whether the device identifies itself as mobile.

The parsing works by looking for known markers in the string, and the order in which it checks them is what makes the answer reliable in the common cases. Several browsers include the name of another browser in their own string for compatibility, so a naive check would report the wrong one; matching the more specific markers first avoids that, which is why a modern browser on a desktop platform is identified correctly rather than as the older browser it mentions.

Its limits come from being a fixed list of patterns rather than a maintained database. Unusual browsers, embedded webviews, command-line clients and scripted requests commonly come back as unknown, and the operating system is recognised from a handful of markers rather than from exhaustive version mapping. And the whole string is self-reported — any client may send whatever it likes, so a user agent is a useful hint for reproducing a bug and worthless as a security control.

How to use User Agent Parser

  1. 1 Paste the complete user agent string from the log or the request headers.
  2. 2 Read the browser and version, the operating system and the mobile indicator.
  3. 3 Treat an unknown result as a signal that the client is not one of the mainstream browsers rather than as a parsing failure.

Frequently asked questions

Why does it sometimes report the wrong browser?

Because user agent strings often name several browsers for historical compatibility, and identification depends on checking the more specific markers before the generic ones. A string that has been deliberately rewritten to look like something else will be identified as whatever it claims to be.

Is the mobile flag reliable?

It is a good indication rather than a fact. Tablets and desktop browsers in a compatibility mode can report the mobile marker, and some browsers on phones omit it. For anything that matters, responsive layout is the dependable approach rather than sniffing the client.

Can I use this for access control?

No. The string is supplied by the client and is trivial to forge, so it cannot be trusted for anything security-related. Its legitimate uses are diagnosing rendering bugs, understanding the traffic mix and producing statistics that tolerate some noise.

Why is a version number sometimes missing?

Version detection needs a numeric version immediately after the marker, and not every client formats it that way. When the pattern does not match, the browser is still identified and the version is left out rather than guessed at.

Free, online, and private

Free to use

User Agent Parser is completely free. There is no account to create, no login, and no hidden charge or usage limit.

Runs online in your browser

It is a free online tool that runs entirely in your browser. Nothing to download or install — open the page and start using it right away.

Your data stays private

All processing happens locally on your device. Your input is never uploaded, stored, or tracked, so it never leaves your browser.

How User Agent Parser behaves in detail

These are the specifics of this implementation — the exact ranges, defaults and fixed settings you are working with.

Parameter Value
Browser tokens seven substrings tested in order: Edg, OPR, Chrome, Firefox, Safari, MSIE and Trident, giving six names
Order effect Edge and Opera are tested before Chrome so they are not misfiled; Safari is only reached when no earlier token appears
Version capture the token is matched against a digits-and-dots pattern, so a version holding a letter is left off
OS branches eight, in order: Windows NT 10, Windows NT 6.3, any other Windows, Android, iPhone, iPad, Mac OS X, Linux
Mobile flag Yes when the string contains Mobi, Android, iPhone or iPad, otherwise No

Compiled from the implementation of this tool and checked against it by itoolnet.

What User Agent Parser does not do

Knowing the edges of a tool saves more time than another list of its features. These are the cases where it will not do what you might expect.

  • It is substring matching against seven tokens, not a user-agent database. A browser that embeds the Chrome token — Brave, Vivaldi, Samsung Internet, Electron or a plain WebView — is reported simply as Chrome, with Chrome's build number as its version.
  • Windows 11 cannot be distinguished from Windows 10: both send NT 10.0, so the first pattern matches and reports "Windows 10/11", while other NT versions such as 6.1 for 7 fall into the generic "Windows" bucket.
  • Nothing beyond those three rows is extracted. There is no device model, no rendering engine, no CPU architecture and no crawler detection, so a crawler is reported as whatever browser token its string happens to carry, or as Unknown if it carries none.

Tested and documented by itoolnet, the team that builds and maintains this site.

Share & embed this tool

Writing a guide or article? You are welcome to link to User Agent Parser with the snippet below. It is free, runs entirely in your browser, and needs no signup.