Technical
DNI electrónico (DNIe) verification by NFC: a business guide
NFC verification reads the chip in a supported eID or e-passport and checks its cryptographic signature, and separate liveness and face match steps compare the chip portrait with a live face.

Contents
In this guide
Jump to the part you need.
DNI electrónico verification by NFC reads the chip in a supported eID or e-passport with the phone's radio and checks its cryptographic signature, and separate liveness and face match steps compare the chip portrait with a live face. Our docs do not establish Spanish DNI coverage, so check the supported documents page before you promise it. It fits Spanish banking and gambling sign-ups. A full-KYC check with NFC reading costs $0.48 at list price: $0.33 KYC plus the $0.15 NFC add-on. Chip reading needs our native iOS or Android SDK, not a browser.
Prices checked against the live Didit price feed on November 26, 2026.
| Question | Answer |
|---|---|
| What it checks | The chip in a supported eID or e-passport: chip authenticity, chip data and the chip portrait, plus liveness and face match as separate steps in the same workflow. Check the supported documents page for Spanish DNI coverage before you promise it |
| Where it runs | Didit native iOS and Android SDKs inside a hosted session. Not in a web browser |
| Price per completed check | $0.48 at list price for a full-KYC check with NFC reading: $0.33 KYC plus the $0.15 NFC add-on |
| Prerequisites | Workflow with ID Verification and NFC, API key, a phone with NFC and a native build, a document route in the same workflow |
| Main failure to design for | No NFC radio on the device: the chip step is skipped, nfc_skip_reason records why, the document check still runs |
| Fastest way to test | Free sandbox at business.didit.me, no sales call |
Start free in the sandbox at business.didit.me (no sales call). Developers can connect Didit to an AI assistant through MCP. The chip steps live in the NFC verification docs, sandbox rehearsal is described in sandbox testing, and every list price is on didit.me/pricing.
What the DNI electrónico is
The DNI electrónico is Spain's national identity card with a chip, issued by the Ministerio del Interior through the Dirección General de la Policía. The chip carries the holder's photo, personal data and the certificates used for signing, alongside the printed data and the machine-readable zone on the back.
Newer DNI cards expose the chip over a contactless interface, so a phone with NFC can read them without a card reader. Older cards are contact only: they need a reader and cannot be read by a phone, which matters when you promise a chip route to your whole Spanish user base.
One caution before you commit. A published price does not establish production availability, so open the Spanish DNI entry on Didit's supported documents page, then run a real card through the sandbox before you write chip coverage into a customer promise.
Card and device compatibility
What matters for an onboarding flow is whether the card in the user's hand has a contactless chip the phone can read. That is a document and device compatibility question, so confirm the Spanish DNI entry on Didit's supported documents page before you promise a chip route.
So do not treat the word DNIe as a promise of chip reading. A card with a long validity issued years ago can still be in use, and part of your base may hold a contact-only card. Offer the chip path first, keep the document path visible, and record which path each user took so you can see the split in your own data.
Prerequisites before your first DNIe session
- A workflow that includes the NFC feature. NFC normally runs alongside ID Verification, created in the Business Console or with
POST /v3/workflows/. - An application and an API key. Sandbox testing is free and unlimited on every plan, so you can rehearse every fallback as often as you need.
- A native build. Chip reading runs in the iOS SDK and the Android SDK, on iOS 13 or later and on Android phones with NFC enabled. Safari on iOS has no Web NFC API and Chrome on Android ships an experimental one, so web builds skip the chip.
- A document route in the same workflow for foreign residents, for contact-only cards and for phones without an NFC radio.
- A written rule for the chip result: which warning codes stop onboarding and which send a person to review. Decide it before the first live session, not after.
How to verify a DNIe by NFC: seven steps
- Build the workflow. Put ID Verification and NFC in the same workflow. The user photographs the document first, the SDK derives the BAC and PACE keys from the MRZ, and only then does the chip open.
- Create the session. Call
POST /v3/session/withworkflow_id,vendor_dataand acallback. Send your stable user id invendor_data, because it binds the session to the person and drives duplicate detection. - Open the session on the device with the radio. Either open the returned
session.urlon a phone, or mount the native SDK inside your app. A desktop sign-up has to hand off to the phone, or take the document route. - Photograph the card. The MRZ on the back of the DNI is the key that opens the chip. Without a readable MRZ the chip cannot be read, and the decision carries
MRZ_KEY_UNAVAILABLE. - Tap the card on the phone. The user holds the DNI against the back of the phone and keeps it there until the read finishes. Ask them to remove a thick case first.
- Read the decision. Fetch
GET /v3/session/{sessionId}/decision/, or subscribe tostatus.updated. NFC results arrive in the plural arraynfc_verifications[], and the top-levelnfc_skip_reasonsays why the chip did not run when it did not. - Apply your rule. Decide from the warnings and the chip result together, not from the top-level status alone.
Create the session
curl -X POST 'https://verification.didit.me/v3/session/' \
-H 'x-api-key: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"workflow_id": "YOUR_WORKFLOW_ID",
"vendor_data": "user-123",
"callback": "https://yourapp.com/post-kyc"
}'
Fetch the decision
curl https://verification.didit.me/v3/session/SESSION_ID/decision/ \
-H "x-api-key: YOUR_API_KEY"
Read the result from a webhook instead of polling
Subscribe a destination to status.updated, verify the X-Signature-V2 header over the raw request body with your destination secret, and check that X-Timestamp is within 300 seconds. Then read decision.nfc_verifications[] in the payload. The older X-Signature-Simple header authenticates the envelope only, so if you verify with it, fetch the decision from the API instead of trusting the body. The webhooks docs list every header and event type.

Expected output
A completed DNIe read returns a user session with the chip report inside nfc_verifications[]. The shape below cuts the payload down to the fields you branch on.
{
"session_id": "00000000-0000-0000-0000-000000000000",
"session_kind": "user",
"status": "Approved",
"nfc_skip_reason": null,
"id_verifications": [{ "status": "Approved" }],
"liveness_checks": [{ "status": "Approved" }],
"face_matches": [{ "status": "Approved" }],
"nfc_verifications": [
{
"status": "Approved",
"is_nfc_skipped": false,
"skip_reason": null,
"chip_protocol": "icao",
"warnings": []
}
]
}
Always read from the plural array. The V3 schema keeps the name nfc_verifications[] even when a workflow has a single NFC node, and an integration that looks for a singular nfc_verification key finds nothing. Each item also carries chip_data and authenticity next to its status and warnings, and chip_protocol tells you whether the read was ICAO or JPKI. If the user skipped the chip or the device had no NFC radio, the array is empty and nfc_skip_reason carries the reason.

Inputs and outputs
| Direction | Field | What it does |
|---|---|---|
| You send | workflow_id | The UUID of the workflow that contains ID Verification and NFC |
| You send | vendor_data | Your stable user id, used for duplicate detection across sessions |
| You send | callback | Where the hosted flow sends the user when it finishes, with the session id and status appended |
| You send | language | ISO 639-1 code for the verification UI, for example es |
| You send | expected_details | Name, date of birth, nationality or document country you already hold; mismatches surface as warnings |
| You send | metadata | Arbitrary JSON echoed back in responses and webhooks, never shown to the user |
| You read | status | Session status: Approved, Declined, In Review, In Progress, Not Started, Expired, Abandoned, Kyc Expired, Resubmitted, Awaiting User |
| You read | session_kind | user or business; branch on it before anything else |
| You read | nfc_verifications[] | One item per NFC step, with status, chip protocol, chip data, authenticity and warnings |
| You read | nfc_skip_reason | Top-level reason the chip did not run, from USER_SKIPPED to DEVICE_WITHOUT_NFC |
| You read | warnings[] | Risk codes per feature, each with a short and a long description you can show an agent |
Failure cases and recovery
The chip reports its own warning codes under warnings[] with feature set to NFC. Treat the table below as a default rule set and write your own version into policy.
| Warning | What happened | What to do |
|---|---|---|
NFC_NOT_READ | The card moved away before the read finished | Allow a retry in the same session, with instructions on where to hold the card |
NFC_BAC_FAILED | The MRZ key did not open the chip | Retry with a fresh document photo, since the photo supplies the key |
NFC_DATA_INVALID | Chip data failed validation | Do not approve; send to review |
NFC_DATA_DOES_NOT_MATCH_OCR | The chip and the printed data disagree | Likely a tampered document. Do not approve |
NFC_PASSIVE_AUTHENTICATION_FAILED | The chip certificate did not chain back to a trusted CSCA | Stop the flow |
NFC_ACTIVE_AUTHENTICATION_FAILED | The chip failed the active challenge | Treat as high risk and review |
NFC_CHIP_CLONED | The chip looks like a clone | Decline |
NFC_DOCUMENT_REVOKED | The issuer lists the document as revoked | Decline |
When the chip never runs, the session is not a failed check. The SDK falls back to OCR and face match, and nfc_skip_reason explains it: USER_SKIPPED, DOCUMENT_WITHOUT_CHIP, CHIP_CERTIFICATE_UNAVAILABLE, DEVICE_WITHOUT_NFC, INTEGRATION_WITHOUT_NFC_ACCESS or MRZ_KEY_UNAVAILABLE. Log the reason with the decision. It tells you how often your base is on old cards, on old phones, or on a web build with no chip access, and each of those needs a different fix.
Paid steps and review boundaries
Billing is per completed check, from prepaid credit. A DNIe read with the chip inside a full KYC workflow bills these lines.
| Step | Price | When it bills |
|---|---|---|
| ID document verification | $0.15 | The DNI photo and OCR |
| Passive liveness | $0.10 | The selfie capture |
| Face match 1:1 | $0.05 | Selfie against the document photo or the chip portrait |
| Device and IP analysis | $0.03 | 200+ fraud signals on the session |
| NFC reading | $0.15 | Add-on, billed on a check where the chip read runs |
| AML screening | $0.20 | Optional step, 1,300+ lists |
| Proof of address | $0.20 | Optional, when your flow needs a residence check |
Model the share of your base that will use the document route from your own session data, not from an assumption, and review it after the first month.
The line between us and you is stable. Didit runs the checks and returns the evidence, the warnings and the session record. The onboarding decision, the risk assessment, your choice of route, and your record-keeping as the obliged entity stay with you. Sessions that land In Review are handled by your reviewers in the Console, with the Investigator agent available on paid plans. Some retries and some no-match database lookups are billable, and the docs pricing page lists them.
Worked cost example
A Spanish consumer lender runs 1,000 sign-ups a month. Seven hundred users hold a DNI card with a readable chip and finish on the chip, three hundred fall back to the document route, and everyone is screened against sanctions and PEP lists.
- Chip route: 700 x ($0.33 + $0.15) = 700 x $0.48 = $336.00
- Document route: 300 x $0.33 = $99.00
- AML screening on all 1,000: 1,000 x $0.20 = $200.00
- Total at list price: $336.00 + $99.00 + $200.00 = $635.00, or $0.635 per user
- On Growth, 4% off Didit prices: $635.00 x 0.96 = $609.60
Now shift the mix. If half the base falls back instead of 30%: 500 x $0.48 = $240.00 for the chip route, 500 x $0.33 = $165.00 for the document route, $200.00 of AML screening, so $605.00 in total. The NFC part of that bill is $120.00, not $240.00, because the add-on only applies where a chip read runs. If ten percent of the chip attempts need one retry, add the price of the lines that run again on the retried checks.
Compliance boundary: what a chip read gives you
A chip read is a document check with cryptographic evidence. It shows that the chip is genuine, that the data on it was not altered in transit, and, with the liveness and face match steps, that the person in front of the camera matches the portrait the issuer stored on the chip.
The documented NFC flow reads the chip and validates it. The DNIe is not on our published digital ID wallet list, which covers MitID, BankID Sweden, iDIN, Finnish Trust Network, Smart-ID, Mobile-ID, BankID Norway, Personalausweis Profile 2, Bank iD and Google Wallet. The EUDI Wallet, which lists Spain, is coming soon with the rate published at $0.15 per completed verification.
Your obligations come from the Spanish anti-money laundering law, Ley 10/2010, and its implementing rules, and from the eIDAS framework for electronic identification, Regulation (EU) No 910/2014. Read the official texts, check them against your own procedure, and take legal advice on what applies to your business. We provide the checks and the record, not a legal opinion.
Limits and fallbacks
Four limits decide how the flow behaves in production.
- The DNI is issued to people with Spanish nationality, so a foreign resident has none and needs a passport or a residence permit in the same workflow.
- Cards without a contactless chip cannot be read by a phone. Keep the document route open and route those users to it without a dead end.
- Browsers have no usable NFC access, so a web sign-up either hands off to the native app or finishes without chip evidence.
- The address sits on the back of the card, so plan a second source for the usual place of residence the anti-money laundering rules ask for. Didit prices Proof of Address at $0.20 per check.
Cover the whole Spanish base with one workflow: ID Verification, NFC and the document fallback in a single session. NFC is attempted when the document has a chip and the device can read it, and the session still returns a decision when it cannot.
Sources
- Didit docs: NFC Verification API for e-passport and eID chips
- Didit docs: NFC warning catalogue
- Didit docs: documents supported by NFC reading
- Didit docs: iOS SDK and Android SDK
- Didit docs: Create Session API
- Didit docs: Retrieve Session API
- Didit docs: data models and report objects
- Didit docs: webhooks and signature verification
- Didit docs: sandbox testing
- Didit docs: pricing and billing rules and the Didit pricing page
- Didit MCP server
- Regulation (EU) No 910/2014 (eIDAS), EUR-Lex
- Ley 10/2010 de prevención del blanqueo de capitales, BOE (plain text, no link)
- Policía Nacional DNIe portal, issuer of the DNI electrónico (plain text, no link)
The next step is a free sandbox application at business.didit.me: add ID Verification and NFC to a workflow, run one session on an Android phone with a DNI chip card, and read nfc_verifications[] in the decision. No sales call.
Try it
Try this in the sandbox
Run the check this guide describes, free.
The product this post is about, taken from its topic. Run it free in the sandbox.
Author
Alberto Rosas
Co-founder and CEO

Questions
Frequently asked questions
Can I verify a Spanish DNIe by NFC in a web browser?
No. Chip reading needs native access to the NFC radio, so it runs in the Didit iOS and Android SDKs. Safari on iOS has no Web NFC API and Chrome on Android ships an experimental one. On a web build the chip step is skipped and the session continues with the document photo, liveness and face match.
How much does a DNIe NFC check cost on Didit?
$0.48 per completed check at list price: $0.33 for the full KYC check (ID document $0.15, passive liveness $0.10, face match $0.05, device and IP $0.03) plus $0.15 for the NFC reading add-on. AML screening adds $0.20 when your workflow includes it. Growth takes 4% off Didit prices and Scale takes 10%.
What is DNI 4.0 and does it work with NFC?
Our documented NFC flow reads chips on supported eIDs during a hosted session in the native SDKs. What decides your flow is whether the specific card in the user's hand has a contactless chip a phone can read. Confirm the Spanish DNI entry on Didit's supported documents page before you promise chip coverage, and keep a document route open for cards that cannot be read over the air.
Does NFC chip reading work on Android?
Yes. The Android SDK reads the chip on phones with NFC enabled, and the iOS SDK does the same on iOS 13 or later. The user has to hold the card against the phone until the read finishes, after the document photo supplies the MRZ key. NFC is session-only: there is no standalone NFC endpoint, the chip is read during a hosted session.
What happens if the user's phone has no NFC?
The SDK skips the chip and records why in nfc_skip_reason, for example DEVICE_WITHOUT_NFC or USER_SKIPPED. The flow falls back to OCR and face match, so you get a decision, just without the cryptographic chip evidence. A liveness step runs only when your workflow includes it.
Does Didit support signing in with a DNIe certificate?
The route documented here is the NFC chip read inside a workflow: we read the chip and validate it. The DNIe is not on our published digital ID wallet list. If your procedure relies on a signature made with the DNIe certificate, plan it separately with your own certificate validation and your own legal advice.
Which DNIe warnings should stop onboarding?
Stop on NFC_PASSIVE_AUTHENTICATION_FAILED, NFC_CHIP_CLONED and NFC_DOCUMENT_REVOKED. Do not approve on NFC_DATA_DOES_NOT_MATCH_OCR or NFC_DATA_INVALID, because the chip and the printed card disagree or the chip data failed validation. Allow a retry on NFC_NOT_READ and NFC_BAC_FAILED. The full catalogue is in the Didit NFC warnings docs.
What does the chip give me that a document photo does not?
Cryptographic proof that the document data was signed by the issuer, chip data that a printed card cannot show, and a portrait stored by the issuer rather than printed by whoever made the card. The live face is captured by a separate liveness step and compared by a separate face match step, so you see each result on its own. That combination is why a chip read catches manipulations a photo alone cannot.
Can I run DNIe users and foreign residents in the same workflow?
Yes. Put ID Verification, NFC and the document fallback in one workflow. NFC is attempted when the document has a chip and the device can read it, and the same session falls back to OCR, liveness and face match when it cannot. Branch on session_kind first, then read nfc_verifications[] and nfc_skip_reason to see which path ran.
Is a DNIe chip read enough for Spanish anti-money laundering duties?
A chip read is strong document evidence: it proves the chip is genuine and, with liveness and face match, that the live person matches the issuer's portrait. Whether that satisfies your Spanish obligations depends on the rules that apply to your business and on your own risk assessment. Read Ley 10/2010 and the eIDAS texts, and take legal advice; Didit provides the checks and the session record, not the legal decision.
Compliance built in
Audited, certified and attested.
We hold the certifications and build each country's rules into your flows, so you can launch anywhere without worrying. Security and Compliance center
- Regulation encoded into your flows
Tell us what you do and where. Didit lists the rules that apply to you, with sources, and builds the checks each country needs into one workflow.
- Ready for AMLR
Every requirement of the new EU anti-money laundering rules, from checking customers to human review, is already covered by a Didit check.
- Tested in Spain's Treasury sandbox
Spain's Treasury published its supervised sandbox report on Didit's NFC plus active liveness onboarding; SEPBLAC took part and valued the added measures positively.
- Audited, not self-declared
iBeta Level 1 and Level 2. Liveness tested under ISO/IEC 30107-3.
Your obligations · 3 regions
SOC 2 Type 2
ISO 27001
iBeta Level 1 and Level 2
EU regulator attestation
FSM youth protection
GDPR
EBA remote onboarding
MiCA compatible
FIDO Alliance member
- AMLREU AML Regulation ready
Integration · Didit MCP
Run Didit from your own AI agent
Connect Didit to Claude, Cursor, VS Code or ChatGPT and just ask in plain words. Your agent can do anything you can do in the console, with the same permissions you have.
- Build workflowsDescribe the checks you need. The agent creates and publishes the flow.
- Run investigationsAsk why a session was declined, review cases, search people and companies.
- Change rulesCreate payment rules, test them on past data and switch them on.
- Pull reportsAsk for numbers, exports or the audit log.
Didit Academy


