navigator.appVersion is a read-only string that claims to describe version information about the browser (MDN). The text varies a lot by engine — do not treat it as a stable API.
Read the notes below before you rely on this property. Prefer feature detection when support is limited.
Syntax
Use navigator.appVersion. Start with this line.
JavaScript
navigator.appVersion
Call
What it does
navigator.appVersion
Primary signature.
Built into the browser. Read navigator.appVersion on Navigator — no import required.
Library declarations
JavaScript
navigator.appVersion
Parameters
This member has no parameters beyond those shown in the signature.
Return Value
Return Value
Description
*
The current value of navigator.appVersion.
JavaScript Examples
Example 1 — Read appVersion
Log the version-like string from navigator.
JavaScript
console.log(navigator.appVersion);
// Chrome-like: long string · Firefox: often short
appVersion: 5.0 (… Chrome/… )
userAgent: Mozilla/5.0 (… Chrome/… )
lengths: 110 118
UA without Mozilla/ equals appVersion? true
How It Works
Read both strings. Capture appVersion and userAgent.
Compare lengths. Firefox often keeps appVersion much shorter.
Optional strip test. Remove a leading Mozilla/ from UA and compare.
Lesson. Related in some engines — never a portable contract.
Example 3 — Feature Detect Instead
Skip version sniffing — branch on a real capability.
JavaScript
console.log("appVersion (demo only):", navigator.appVersion);
// Prefer this style for real apps:
if ("serviceWorker" in navigator) {
console.log("serviceWorker available");
} else {
console.log("serviceWorker missing");
}
appVersion (demo only): 5.0 (…)
serviceWorker available
How It Works
Show the string. Log appVersion for learning only.
Do not parse it. Avoid includes("Chrome") for product logic.
Feature detect. Use in on the API you need.
Branch safely. Capabilities beat brittle version text.
Compatibility
Browser Support
navigator.appVersion is marked Baseline Widely available on MDN (since July 2015). Support is universal — the value shape is not.
✓ Baseline · Widely available
Navigator.appVersion
Read-only version-like string. Available everywhere; format differs by browser. Unreliable for detection — prefer feature detection.
100%Widely available
Google ChromeAll versions · Desktop & Mobile
Full support
Mozilla FirefoxAll versions · Desktop & Mobile
Full support
Apple SafariAll versions · macOS & iOS
Full support
Microsoft EdgeAll versions · Chromium & Legacy
Full support
Internet ExplorerIE 6+ · Legacy environments
Full support
OperaAll modern versions
Full support
appVersionExcellent
Bottom line: Safe to read for demos. Never use it for browser or version detection in product code — detect the feature you need instead.
Frequently Asked Questions
A string with version-like browser information. The exact text varies a lot by browser — sometimes nearly a userAgent without the Mozilla/ prefix, sometimes a short platform hint.
No. Chrome-like browsers often return a long string; Firefox often returns a short string such as "5.0 (Macintosh)". Treat the format as browser-dependent.
It is unreliable and not recommended. MDN points to User-Agent reduction and browser-detection pitfalls. Prefer feature detection instead.
In some browsers appVersion looks like userAgent with Mozilla/ removed. In others it is much shorter. Do not assume they stay in sync forever.
No. It is a read-only Navigator property. You read it; you do not assign a new value.
Feature detection (for example "serviceWorker" in navigator) or well-supported APIs — not parsing appVersion for product logic.