TOOLS / APDU RESPONSE

APDU response codes.

Decode SW1/SW2 and find the next step.

Use the final two bytes of a card response. Windows/PCSC transmit errors are separate. Meanings can vary by command and card profile; this tool sends no commands.

39 codes and patterns

SW1 SW2Meaning & next stepCategory
9000Command completed

Use the returned data according to the command.

Success
61XXResponse data available

Use GET RESPONSE as required by the card and transport; SW2 supplies the short response length.

Continuation
6200Warning without further detail

Inspect the command specification; non-volatile memory is unchanged.

Warning
6281Returned data may be corrupted

Do not assume the returned data is intact.

Warning
6282End of file or record reached

The response may contain fewer bytes than requested.

Warning
6283Selected file invalidated

Check the file lifecycle and application rules.

Warning
6284File control information is malformed

Check the selected file and expected FCI format.

Warning
6300Warning without further detail

Non-volatile memory may have changed; consult the command definition.

Warning
63CXCommand-specific counter

X is a counter. For VERIFY, it usually gives remaining PIN/password attempts; other commands may use it differently.

Warning
6400Execution failed; memory unchanged

Check the card state and command-specific documentation.

Error
6500Execution failed; memory changed

Inspect application state before repeating a state-changing command.

Error
6581Memory failure

The card reported a storage problem.

Error
6700Invalid length

Check Lc, Le, and the actual command-data length.

Error
6800CLA function unsupported

Check class-byte features against the selected application.

Error
6881Logical channel unsupported

Check the channel encoded in CLA.

Error
6882Secure messaging unsupported

Check whether this application accepts the requested secure messaging mode.

Error
6900Command not allowed

Check application state and command prerequisites.

Error
6981File structure incompatible

Select a file whose structure supports this operation.

Error
6982Security requirements not met

Complete the required authentication or secure-channel setup.

Error
6983Authentication method blocked

Use the documented recovery procedure; repeated guesses will not unblock it.

Error
6984Referenced data invalidated

Check the lifecycle of the referenced object.

Error
6985Conditions of use not satisfied

Check application selection, lifecycle and preceding commands.

Error
6986No current elementary file

Select the required EF before retrying the operation.

Error
6987Secure messaging objects missing

Check the protected command structure.

Error
6988Secure messaging objects incorrect

Check secure-channel state, MAC and encrypted data.

Error
6A80Command data invalid

Check the data encoding and required fields.

Error
6A81Function unsupported

Check whether the card implements this operation.

Error
6A82File or application not found

Check the AID or file identifier; this does not prove the card is empty.

Error
6A83Record not found

Check the record number and file selection.

Error
6A84Insufficient memory

Check space requirements for the operation.

Error
6A85Lc inconsistent with TLV data

Check each TLV length and the total command-data length.

Error
6A86P1 or P2 invalid

Check the command parameter bytes.

Error
6A87Lc inconsistent with P1/P2

Check the data length required by these parameters.

Error
6A88Referenced data not found

Check the requested tag, key or object identifier.

Error
6B00Parameter error

Check P1/P2, including any offset.

Error
6CXXIncorrect expected response length

Reissue the command with corrected short Le from SW2, if the card profile permits.

Correction
6D00Instruction unsupported

Check INS and the currently selected application.

Error
6E00Class unsupported

Check CLA, channel and application class.

Error
6F00Unspecified card error

Consult the application documentation and diagnostic logs.

Error

X represents a hexadecimal digit. This is a core reference, not an exhaustive registry of vendor-specific responses.

ISO 7816-4 status-word reference (CardWerk) ↗ · OpenPGP card specification ↗

Calculator reference

Verification evidence and limitations →

What it calculates

Explains APDU status words returned by a card.

Inputs and methods

Two-byte HEX SW1/SW2 value; meanings may depend on the application.

Worked example

Enter 9000.

Success

Specification and limits

A success status says the command completed; it does not identify the returned data format.

EMV specifications ↗