A UK sort code is the 6-digit number that identifies which bank and branch a current or savings account belongs to. It appears on cards, cheques and bank statements, usually grouped as three pairs like 12-34-56. This free validator checks that a sort code is structurally correct and tells you which bank the leading digits point to — useful when pre-validating payment forms or de-duplicating supplier records.
How it works
A sort code is exactly 6 digits, conventionally written as three pairs separated by dashes. The validation here has two parts:
- Format check — strip any spaces and dashes, then confirm exactly 6 numeric digits remain.
- Bank identification — the first two digits map to a clearing bank using publicly documented ranges. For example
04is Monzo,20–29is Barclays,30–39is Lloyds,40–49is HSBC,60–62is NatWest, and09/07are Santander legacy ranges.
The leading-digit map is best-effort: it identifies the bank, not the specific branch. The authoritative branch directory and the per-account modulus check require Vocalink’s EISCD/modulus data.
Example
Validate 12-34-56 → normalised digits 123456. The format is valid (6 digits). The leading pair 12 falls in the Clydesdale/Yorkshire Bank range, so the tool reports that bank.
Tips and notes
Because the bank ranges overlap with newer challenger banks and re-assignments happen, treat the bank name as a strong hint rather than a guarantee. For payment-critical flows you should still run the official modulus check before debiting an account. Everything in this tool runs locally — your data never leaves the browser.