Home / Wiki / P / Primary Account Number (PAN)

Primary Account Number (PAN)

Cards and IssuanceUpdated 05 Nov 2026

A primary account number (PAN) is the number that identifies a payment card account. It is the long string of digits embossed or printed on a credit card, debit card or prepaid card, and the same number is stored on the card's magnetic stripe and chip. Merchants, processors and card networks use it to work out which bank issued the card and which account a purchase should be charged to.

The PAN is defined by the international standard ISO/IEC 7812, which sets its structure and length (up to 19 digits; most cards carry 16). It is distinct from the security values that travel with it, such as the expiry date, the card verification value (CVV) and the personal identification number (PIN). Because a PAN alone can be enough to attempt a fraudulent online purchase, its storage and handling are governed by the card industry's data security rules.

01

Primary account number in plain terms

Think of a PAN as a postal address for money. The first part says which city and post office the letter is going to (the bank that issued the card), the middle part names the house (the cardholder's account), and the last digit is a quick spelling check that catches most typing mistakes before the letter is even posted.

Because anyone who knows the address can try to send a bill to it, businesses are told to keep the full number locked away, show only a few digits on receipts and screens, and swap it for a stand-in number wherever they can.

02

Structure of a PAN

A PAN has three parts, read from left to right:

  • Issuer identification number. The leading digits, also called the bank identification number (BIN), identify the card issuer and often the card product and country. The first digit is the major industry identifier: 4 for Visa, 5 (and the 2-series range) for Mastercard, 34 and 37 for American Express. Since the 2017 revision of ISO/IEC 7812-1, the issuer identification number has been 8 digits long instead of 6, and the networks moved their routing tables to the longer format.
  • Individual account identifier. The middle digits, assigned by the issuer, point to the cardholder's account. A single account can have several PANs, for example when a card is replaced or a second card is issued to a family member.
  • Check digit. The final digit is calculated with the Luhn algorithm and lets any system reject most mistyped numbers without contacting the issuer.
03

The Luhn check digit

The Luhn (or "mod 10") check works on the digits from right to left. Every second digit, starting with the one next to the check digit, is doubled, and 9 is subtracted from any result above 9. A number passes when the total of all the resulting digits is a multiple of ten:

(∑i=1ndi′) mod 10=0\left( \sum_{i=1}^{n} d_i' \right) \bmod 10 = 0
  • di′d_i' is the ii-th digit counted from the right, doubled (and reduced by 9 if above 9) when ii is even, left as it is when ii is odd.
  • nn is the number of digits in the PAN, check digit included.

The textbook test number 79927398713 shows how it works. The undoubled digits (3, 7, 9, 7, 9, 7) add up to 42. The doubled digits (1, 8, 3, 2, 9) become 2, 7, 6, 4 and 9, which add up to 28. The total is 70, which divides evenly by ten, so the number is valid. The check only catches typing errors; it says nothing about whether the account exists or has funds.

04

How the PAN moves through a payment

In a typical four-party card model, the merchant's payment gateway sends the PAN, amount and other data to the acquirer. The acquirer reads the issuer identification number and forwards the authorization request across the relevant card network to the issuer, which approves or declines it. The PAN also appears in clearing files and any chargeback case.

In card-present payments the chip produces a one-time cryptogram, so a copied PAN is of limited use at the terminal. In card-not-present commerce the PAN, expiry date and CVV are often all a fraudster needs, which is why stolen card numbers trade on criminal markets.

05

Protecting the PAN

The Payment Card Industry Data Security Standard (PCI DSS), maintained by the PCI Security Standards Council founded by the major card brands, sets the rules for any business that stores, processes or transmits card data. Version 4.0.1, published in June 2024, is the current version as of 2026. Its main requirements on the PAN are:

  • Masking on display. When shown on screens or receipts, the PAN is masked so that at most the issuer identification number and the last four digits are visible, unless a person has a documented business need to see more.
  • Unreadable storage. A stored PAN must be rendered unreadable, for example by strong encryption, truncation, keyed hashing or index tokens.
  • No storage of sensitive authentication data. The CVV, full magnetic-stripe data and PIN blocks may not be kept after authorization, even if encrypted.

Tokenization goes further by replacing the PAN with a surrogate value. Network tokenization, run by the card schemes, issues a token that is tied to one merchant or device, so a breach exposes tokens that cannot be used elsewhere. Chip specifications managed by EMVCo pursue the same goal: making a stolen PAN as worthless as possible.

The PAN is often confused with other account numbers. A bank account used for transfers is identified by an account number and sort or routing code, or internationally by an International Bank Account Number (IBAN); these do not run on card rails. The PAN is also different from the issuer-side account in the core banking system: the issuer maps one or more PANs to that internal account. In data security and privacy law, a full PAN is generally treated as personal identifiable information when it can be linked to a cardholder.

Last updated 05 Nov 2026