Skip to content
CardTools

APDU Status Word Lookup

What 9000, 6A82, 6985 and the rest of SW1SW2 actually mean.

Runs entirely in your browser. Nothing you paste is uploaded, logged or stored.

Try:

ISO 7816-4 status words

CodeMeaning
Success
9000SuccessokNormal processing completed. No further qualification.
61XXMore data availableokXX more bytes are waiting. Issue GET RESPONSE with Le = XX.
Warning
62XXWarning — state unchangedwarnProcessing completed with a warning; the card state did not change.
6281Returned data may be corruptedwarn
6282End of file or record reached earlywarnFewer bytes were available than requested.
6283Selected file is deactivatedwarnHistorically "invalidated". The application is blocked.
6284File control information badly formattedwarn
6285Selected file is in termination statewarn
63XXWarning — state changedwarn
6300Authentication failedbadVerification failed with no counter information.
6381File filled up by the last writewarn
63CXVerification failed — X tries remainingbadThe low nibble is the remaining PIN attempt count. 63C0 means the PIN is now blocked.
Execution error
6400Execution error — state unchangedbad
6401Immediate response required by the cardwarn
6500Memory failure — state changedbad
6581Memory failurebad
6600Security-related issuebad
Checking error
6700Wrong lengthbadLc or Le is wrong for this command. Usually a terminal-side bug.
6800Functions in CLA not supportedbad
6881Logical channel not supportedbad
6882Secure messaging not supportedbad
6883Last command of the chain expectedbad
6884Command chaining not supportedbad
6900Command not allowedbad
6981Command incompatible with file structurebad
6982Security status not satisfiedbadA required authentication step has not been performed.
6983Authentication method blockedbadPIN blocked. The try counter has reached zero.
6984Reference data not usablebadOften means the PIN reference data is invalidated.
6985Conditions of use not satisfiedbadThe commonest EMV failure after 6A82. The card will not do this now — usually the command arrived out of sequence, or a prerequisite (GPO, PIN, prior AC) is missing.
6986Command not allowed — no current EFbadYou need to SELECT a file first.
6987Expected secure messaging objects missingbad
6988Incorrect secure messaging data objectsbad
6A00Wrong parameters P1-P2bad
6A80Incorrect parameters in the command data fieldbad
6A81Function not supportedbad
6A82File or application not foundwarnThe AID you selected is not on this card. Very common when a terminal tries an AID list in order — a 6A82 here is normal, not an error.
6A83Record not foundbadA READ RECORD asked for a record outside the AFL.
6A84Not enough memory space in the filebad
6A85Lc inconsistent with the TLV structurebad
6A86Incorrect parameters P1-P2bad
6A87Lc inconsistent with P1-P2bad
6A88Referenced data not foundbadA GET DATA asked for a tag the card does not hold.
6A89File already existsbad
6A8ADF name already existsbad
6B00Wrong parameters — offset outside the EFbad
6CXXWrong Le — XX is the correct lengthwarnRe-issue the command with Le = XX.
6D00Instruction code not supported or invalidbadThe card does not implement this INS byte.
6E00Class not supportedbadThe card does not implement this CLA byte.
6F00No precise diagnosisbadThe card failed but will not say why. Often a genuine card fault or an unhandled internal exception.
Cards may return proprietary status words outside these ranges. If a code is not here, check the card platform documentation — GlobalPlatform and individual Java Card applets define their own.

How to read SW1SW2

Every APDU response ends with two status bytes. 9000 is plain success. Anything starting 61 or 62-63 is a warning — the command worked, with caveats. Anything starting 64-6F is an error, and the second byte qualifies it.

Some codes carry data in the low byte. 61XX means XX more bytes are waiting for a GET RESPONSE. 6CXX means your Le was wrong and XX is the correct length. And 63CX is the one worth memorising: the low nibble is the number of PIN attempts remaining, so 63C2 means two tries left and 63C0 means the PIN is now blocked.

The two you will actually see

6A82 — file or application not found. Usually not an error at all. Terminals work through a candidate AID list and a 6A82 simply means "this card does not have that application". Seeing several before a 9000 is completely normal.

6985 — conditions of use not satisfied. The card will not do this right now. Nearly always a sequencing problem: GET PROCESSING OPTIONS before SELECT, a second GENERATE AC without a first, READ RECORD outside the AFL, or a PIN verification that was required and skipped. When you get a 6985, look at the command that came before it.

Codes that mean "your terminal is wrong"

6700 (wrong length), 6A86 (incorrect P1-P2), 6D00 (unsupported instruction) and 6E00 (unsupported class) all point at the command you constructed rather than the card. 6F00 — no precise diagnosis — is the card giving up without explanation, and usually indicates a genuine card fault or an unhandled exception in the applet.

More EMV chip tools