Skip to Content
Platform.Ontology

Web NFC

Asks to read or write NFC tags with your phone.

Asks you firstHardware and accessoriesPeripheralsWeb browsersWhile you use it

In one line

Can scan NFC tags or save to them with your phone, after you allow it

Asks to read or write NFC tags with your phone.

Lets a page scan NDEF tags and write to them. Only while the page is visible and focused. Android Chrome only.

What it can and can't do

What the user does: You tap Scan tag or Save to tag, then hold your phone near it.

It can

  • Scan an NFC tag when your phone touches it
  • Save text or a link onto a tag after a tap
  • Scan only while the page is open and in front

It cannot

  • Work in the background or when you switch apps
  • Save onto a tag without a tap on the page
  • Use your phone's wallet or payment cards
  • Work on iPhone, desktop or most browsers other than Chrome on Android

How it differs between platforms: Only Chrome on Android supports it. iPhone and other browsers do not.

Browser support

BrowserStatusFirst versionReleasedNote
ChromeNot supportedNot availableNot listedNone
EdgeNot supportedNot availableNot listedNone
FirefoxNot supportedNot availableNot listedNone
SafariNot supportedNot availableNot listedNone
Safari on iPhoneNot supportedNot availableNot listedNone
Chrome on AndroidSupported892021-03-02None
Samsung InternetNot supportedNot availableNot listedNone

How a site asks for it

APInew NDEFReader(); reader.scan(); reader.write(); permission nfc
Permission namenfc
Browser compat keysapi.NDEFReader
How access is grantedprompt
What the user seesChrome Android prompt: Scan NFC tags; needs a gesture to write.
Needs a secure context (HTTPS)Yes
Needs a user gestureYes
How long it lastsPersistent per origin
How to take it backSite settings
Inside an iframeTop-level only (not delegated)

Typical flow

  1. Click
  2. ndef.scan()
  3. Prompt
  4. Reading event delivers records

Data you get

What comes back: NDEF records (url, text, mime, smart poster)
Shape: event
How often: per tag scan

FieldTypeUnitRangePrecision
serialNumberstringhextag UID, 4 to 10 byteshigh entropy
recordsarrayNDEFper tagtag content

Technical limits

  • Android Chrome only
  • Page must be visible

The story

What it is

A site asks to read or write NFC tags using your phone.

For you

You tap your phone to a tag or card and the page reads it. It only works while the page is open and on screen, and only on Chrome for Android.

For makers

Makers can build tag based tools without a native app: event check in, inventory, product info and smart posters.

Where you see it

TypeExampleApps
travelYou tap an NFC tag at a hotel to check in on the hotel's website.None named
shoppingA tag on a shirt opens its product page with sizes.None named
liveEvent staff scan NFC tickets with a phone browser to let people in.None named
gamesA web based scavenger hunt reads tags hidden around a city.None named
enterpriseA warehouse worker taps a tag on a shelf to update inventory.None named
securityA cloned tag could be used to trick a page that trusts what it reads.None named

Risks

  • Tag tracking
  • Android only

What the platform says

  • Google: Web NFC. Chrome's docs say Web NFC lets sites read and write NFC tags on Android.

Good uses and abuse

Legitimate uses

  • Ticketing
  • Inventory tags

Known abuse

  • Tag tracking

Scores

ScoreValueMeaning
Sensitivity3 of 5How revealing the data is
Utility2 of 5How useful it is to honest apps
Friction2 of 5How much the user has to do
Fingerprint bits5Rough identifying entropy, when known

History

  • 2021-03, Chrome 89: Web NFC ships on Android
  • Permissions API. Can check whether you allowed or blocked a feature, without asking you

Sources

How well checked: Based on official documentation.

On this page