JavaScript Navigator productSub Property

Beginner
⏱️ 8 min read
📚 Updated: Jul 2026
🎯 5 Examples
🚀 5 Try-it labs
Baseline

What You’ll Learn

navigator.productSub is a legacy Navigator property. Per MDN it returns either "20030107" or "20100101". Learn the typical values, why sniffing is a bad idea, five examples, and better alternatives.

01

Kind

Read-only property

02

Returns

"20030107" or "20100101"

03

Chrome / Safari

"20030107"

04

Firefox

"20100101"

05

Baseline

Widely available

06

Prefer

Feature detection

Introduction

The name productSub looks like a build or product version date. In practice it is a fixed compatibility string that browsers expose as either "20030107" or "20100101".

MDN notes the usual pattern: Apple Safari and Google Chrome return "20030107"; Firefox returns "20100101". Older Internet Explorer returned undefined.

💡
Beginner tip

Do not treat productSub as a trustworthy calendar date or as a browser detector. Learn the values for legacy code, then use feature detection in real apps.

It sits next to navigator.product in the same family of old identification labels.

Understanding the productSub Property

productSub is a read-only string on Navigator (or undefined in legacy IE). The date-like shape is historical; modern engines keep a constant token for compatibility.

  • Value is either "20030107" or "20100101" in modern browsers.
  • Chrome, Chromium Edge, Safari: typically "20030107".
  • Firefox: typically "20100101".
  • IE: historically undefined.
  • Not a reliable way to identify brands in new code.

📝 Syntax

General form of the property:

JavaScript
navigator.productSub

Value

  • Either "20030107" or "20100101".
  • May be undefined in very old Internet Explorer.

Common patterns

JavaScript
console.log(navigator.productSub);
// Chrome / Safari: "20030107"
// Firefox: "20100101"

const known = ["20030107", "20100101"];
const isKnownToken = known.includes(navigator.productSub);

// Prefer feature detection instead of sniffing:
if ("serviceWorker" in navigator) {
  // safe to use service workers
}

⚡ Quick Reference

GoalCode / note
Read the valuenavigator.productSub
Chrome / Safari (typical)"20030107"
Firefox (typical)"20100101"
IE (legacy)undefined
Typetypeof navigator.productSub // "string"
Identify browser?No — do not sniff with this
Better approachFeature detection on APIs / CSS

🔍 At a Glance

Four facts to remember about navigator.productSub.

Values
2 tokens

20030107 / 20100101

Kind
string

Read-only

Looks like
YYYYMMDD

Not a real date

Sniffing
avoid

Unreliable

📋 product vs productSub vs Feature Detection

productproductSubFeature detection
Typical value"Gecko""20030107" or "20100101"N/A
Varies by browser?No (always Gecko)Historically yes (two tokens)Checks capability
Identifies brand?NoUnreliableChecks capability
Best forLegacy triviaLegacy triviaReal application logic

Examples Gallery

Examples follow MDN navigator.productSub behavior. Prefer Try It Yourself — Chromium/Safari often show 20030107; Firefox shows 20100101.

📚 Getting Started

Read the token and map it to the MDN notes.

Example 1 — Read productSub

Log the current value (same idea as MDN’s example).

JavaScript
console.log("productSub: " + navigator.productSub);
Try It Yourself

How It Works

Sample output shows Chromium/Safari. Firefox typically prints 20100101.

Example 2 — Classify Known Tokens

Label the two MDN values without claiming a brand.

JavaScript
const value = navigator.productSub;
let note = "other / missing";

if (value === "20030107") {
  note = "common Chromium / Safari token (MDN)";
} else if (value === "20100101") {
  note = "common Firefox token (MDN)";
}

console.log("value: " + value);
console.log("note: " + note);
console.log("Do not use this as a browser detector.");
Try It Yourself

How It Works

Teaching the MDN mapping is fine; gating features on it is not.

📈 Practical Patterns

Type checks, related legacy labels, and feature detection.

Example 3 — Type and Presence

Confirm the string type and guard for missing values (legacy IE).

JavaScript
const value = navigator.productSub;
const lines = [
  "value: " + String(value),
  "typeof: " + typeof value,
  "isDefined: " + (typeof value !== "undefined")
];
console.log(lines.join("\n"));
Try It Yourself

How It Works

Modern browsers expose a string. MDN notes IE returned undefined.

Example 4 — Legacy Label Family

Compare productSub with product and other fixed labels.

JavaScript
const lines = [
  "product: " + navigator.product,
  "productSub: " + navigator.productSub,
  "appCodeName: " + navigator.appCodeName,
  "appName: " + navigator.appName
];
console.log(lines.join("\n"));
console.log("These are compatibility labels — not brand detectors.");
Try It Yourself

How It Works

Seeing the family together makes the legacy story clear for beginners.

Example 5 — Prefer Feature Detection

Keep productSub for learning; use capability checks for features.

JavaScript
const lines = [];
lines.push(
  "productSub: " + navigator.productSub + " — ignore for sniffing"
);
lines.push(
  "serviceWorker: " +
    ("serviceWorker" in navigator ? "available" : "missing") +
    " — use this for features"
);
console.log(lines.join("\n"));
Try It Yourself

How It Works

Capability checks stay accurate even when compatibility tokens look like dates.

🚀 Common Use Cases

  • Learning Navigator history — understand the two fixed date-like tokens.
  • Legacy code review — spot sniffing that branches on 20030107 / 20100101.
  • Interview / trivia — know Chrome/Safari vs Firefox MDN notes.
  • Not for browser detection — never gate features on productSub.
  • Not for real versioning — it is not a trustworthy release date.

🧠 How navigator.productSub Works

1

Engine exposes a token

Browsers keep a compatibility string that looks like YYYYMMDD.

Compat
2

Script reads the property

Your code accesses navigator.productSub.

Read
3

One of two common values

MDN: 20030107 (Chrome/Safari) or 20100101 (Firefox).

Value
4

New code ignores it

Detect APIs instead of branching on productSub tokens.

📝 Notes

  • Baseline Widely available (MDN, since July 2015).
  • Not Deprecated, Experimental, or Non-standard — no status banner required.
  • Returns "20030107" or "20100101"; IE historically returned undefined.
  • Read-only string on Navigator in modern browsers.
  • Related: product, scheduling, appCodeName, Window.

Universal Browser Support

navigator.productSub is Baseline Widely available across modern browsers (MDN: since July 2015). Values differ by engine family historically — Chrome/Safari use "20030107", Firefox uses "20100101". IE returned undefined.

Baseline · Widely available

Navigator.productSub

A date-like compatibility token. Useful for understanding legacy sniffing — unreliable for identifying browsers in new code.

Universal Widely available
Google Chrome Typically "20030107" · Desktop & Mobile
Full support
Mozilla Firefox Typically "20100101" · Desktop & Mobile
Full support
Apple Safari Typically "20030107" · macOS & iOS
Full support
Microsoft Edge Typically "20030107" · Chromium
Full support
Opera Typically "20030107" · Modern versions
Full support
Internet Explorer Historically returned undefined (MDN)
Legacy quirk
productSub Excellent

Bottom line: Read productSub to learn the two common tokens, then ignore it for real feature decisions.

Conclusion

navigator.productSub is a Baseline compatibility string that returns either "20030107" or "20100101". Learn the MDN browser notes for legacy code, then prefer feature detection for real application logic.

Continue with scheduling, product, or the JavaScript hub.

💡 Best Practices

✅ Do

  • Expect "20030107" or "20100101"
  • Remember IE could return undefined
  • Use feature detection for capabilities
  • Treat productSub as a legacy compatibility label
  • Document why old code branched on these tokens

❌ Don’t

  • Gate features on productSub === "20100101"
  • Treat the string as a real release date
  • Use it for fingerprinting
  • Try to assign to navigator.productSub
  • Assume Chromium will never change the token

Key Takeaways

Knowledge Unlocked

Five things to remember about productSub

Two date-like tokens — compatibility labels, not brand detectors.

5
Core concepts
🔁 02

Purpose

compatibility

Legacy
🚫 03

Sniffing

do not use

Avoid
🔒 04

Access

read-only

API
🎯 05

Prefer

feature detect

Modern

❓ Frequently Asked Questions

MDN: either the string "20030107" or "20100101". Chrome and Safari return "20030107"; Firefox returns "20100101". Internet Explorer returned undefined.
No. MDN marks it as Baseline Widely available (since July 2015). It is not Deprecated, Experimental, or Non-standard — but it is a legacy compatibility value, not a useful build date.
Do not. Other browsers may change, spoof, or share similar labels. Prefer feature detection for real capabilities instead of sniffing productSub.
It looks like YYYYMMDD, but treat it as a fixed compatibility token, not a trustworthy product release date.
No. It is a read-only Navigator property. You read it; you do not assign a new value.
product always returns "Gecko" in conforming browsers. productSub returns one of two date-like strings that differ by engine family historically — still not reliable for modern sniffing.
Did you know?

The strings "20030107" and "20100101" look like dates (7 Jan 2003 and 1 Jan 2010), but MDN treats them as fixed compatibility values — not live build timestamps you can trust for version checks.

Learn scheduling Next

Experimental API for checking pending input during long tasks.

scheduling →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful