Skip to Content
Platform.Ontology

Storage and cookie availability flags

Tests whether cookies, localStorage, sessionStorage and IndexedDB work.

Gets silentlyDevice detailsBrowser stateWeb browsersWhen the page loadsWhile you use it

In one line

Can check whether cookies and site storage work in your browser

Tests whether cookies, localStorage, sessionStorage and IndexedDB work.

Four booleans plus openDatabase and addBehavior legacy checks. Almost always all true, so low entropy, but they flag locked-down privacy modes and blocked storage.

What it can and can't do

What the user does: Nothing. It happens when the page loads

It can

  • Test cookies, localStorage, sessionStorage, and IndexedDB
  • Spot a locked down privacy mode or blocked storage
  • Choose how to save your settings

It cannot

  • See the contents of your storage for other sites
  • See which sites you visited
  • Learn much; almost everyone gets all yes
  • See your cookies from other sites

Browser support

BrowserStatusFirst versionReleasedNote
ChromeSupported12008-12-11None
EdgeSupported122015-07-29None
FirefoxSupported12004-11-09None
SafariSupported42009-06-08None
Safari on iPhoneSupported3.22010-04-03None
Chrome on AndroidSupported182012-06-27None
Samsung InternetSupported1.02013-04-27None

How a site asks for it

APInavigator.cookieEnabled, window.localStorage, sessionStorage, indexedDB.open()
How access is grantednone
What the user seesNone
Needs a secure context (HTTPS)No
Needs a user gestureNo
How long it lastsread fresh on every page load; nothing stored
How to take it backnone needed (no grant)
Inside an iframeReadable from cross-origin iframes too (same values)

Typical flow

  1. Page script reads the value
  2. No prompt is shown

Data you get

Shape: object
How often: static per session

FieldTypeUnitRangePrecision
cookieEnabled, localStorage, sessionStorage, indexedDBbooleanNonetrue or false eachNot listed

Technical limits

  • Booleans only

The story

What it is

Checks whether cookies and browser storage work, which shows locked down privacy settings.

For you

You never see it. A site quickly tests whether it can save a small note in your browser. If it cannot, you may see a message like Please enable cookies, or a feature may stop working.

For makers

Sites need storage for logins, carts and settings. They check first so the page does not break. The answers also reveal locked down privacy settings, so fraud teams use them too.

Where you see it

TypeExampleApps
shoppingA shop tests whether cookies work, and if not, shows a warning that your cart will not be saved.None named
gamesA browser game checks if it can save progress, and warns that scores will not be kept when storage is blocked.None named
bankingA bank login shows a clear Please enable cookies message instead of a blank error.None named
securityA bot defence tool notes visitors with all storage blocked as slightly more risky.None named
analyticsAn analytics tag falls back to server side counting when it cannot save a cookie.Google Analytics
educationAn online course asks students to enable storage so lesson progress is saved.None named
adsAn ad vendor skips cookie based targeting if storage is blocked.None named

Risks

  • Low value alone
  • Highlights privacy settings

Good uses and abuse

Legitimate uses

  • Graceful degradation

Known abuse

  • Fingerprint bits

Scores

ScoreValueMeaning
Sensitivity1 of 5How revealing the data is
Utility2 of 5How useful it is to honest apps
Friction0 of 5How much the user has to do
Fingerprint bits0.6Rough identifying entropy, when known

A real example: LinkedIn

Storage features detected (BleepingComputer). Read by the LinkedIn APFC fingerprint script (48 features, alleged by BrowserGate, partly confirmed by BleepingComputer).

History

  • 2016-06, paper: AmIUnique: cookies enabled 0.25 bits, local storage 0.36 bits

Sources

How well checked: Checked against real behavior.

On this page