CalculatorsConvertersDeveloperTextAll toolsDirectory
Submit your tool Sign in
Theme
Home/Answers/Developer
How-to

What does my user agent string mean and how do I decode it?

Short answer

A user agent string is the identifier a browser sends with every request, packed with historical tokens like Mozilla/5.0 that exist for compatibility rather than accuracy. To decode one, parse it into the browser, engine, operating system and device type it most likely represents. A browser-based user agent parser does that on your own device, reading any UA string you paste.

Why user agent strings look so strange

Almost every modern browser claims to be Mozilla/5.0 and carries tokens referencing engines it does not use, because decades of servers made decisions by matching substrings, and each new browser imitated the previous ones to avoid being served broken pages. The result is that the useful information, the actual browser and version, the OS, the device class, is buried among compatibility tokens. A parser applies the known patterns and reports what the string most likely represents.

Reading one in practice

Paste a UA string from your access logs, an analytics report or a bug ticket, and the parser breaks out the likely browser, rendering engine, operating system and device type. This is the quickest way to answer questions like which browser a crashing user was on. Treat results as a strong hint rather than gospel: user agents can be arbitrarily spoofed, and modern browsers have frozen or reduced parts of the string to limit fingerprinting.

Logs stay private

UA strings often arrive attached to other log data you should not paste into random sites. The parser runs entirely in your browser, so whatever you paste never leaves your device. The same local-only approach applies to picking apart request URLs from those logs, which a local URL parser splits into protocol, host, path and query.

Step by step

  1. Copy the UA string. Copy the user agent from your logs, analytics or bug report.
  2. Paste it into the parser. Open the user agent parser and paste the string.
  3. Read the breakdown. See the likely browser, engine, operating system and device type.

Frequently asked questions

Can a user agent string be trusted?

Not absolutely. Browsers and bots can send any string they like, so parsing gives the most likely identity, not a guarantee.

Why do all browsers claim to be Mozilla?

Historical compatibility. Servers once keyed features off the Mozilla token, so every later browser included it to avoid broken pages.

Is the string I paste sent anywhere?

No. Parsing happens entirely in your browser.

Related answers