Simply Calculated

IBAN, sort code and account number: the difference

A UK bank account is identified by a 6-digit sort code and an 8-digit account number. That’s how money moves around the UK. An IBAN wraps the same details in an international format so a bank abroad can find your account.

Updated · Checked by a chartered management accountant

What each one is

DetailWhat it identifiesExample
Sort codeThe bank and branch, in 6 digits12-34-56
Account numberYour account at that bank, in 8 digits98765432
Account nameThe person or business the account is held in the name ofJane Smith
IBANYour account anywhere in the world: country, check digits, bank code, sort code and account numberGB82 WEST 1234 5698 7654 32
BIC (SWIFT code)The bank itself, in 8 or 11 characters, not your accountShown by your bank

The examples come from the SWIFT IBAN Registry’s sample UK IBAN and aren’t a real account. Your banking app, online banking and statements show all of these, usually under the account’s details.

How many digits is a UK bank account number?

A UK bank account number has 8 digits, and the sort code has 6, usually written in pairs: 12-34-56. Together they identify one account. The sort code is the part that identifies the bank and branch, so you can’t tell which bank an account is with from the account number alone.

If you’re not sure which number is which on a statement, the sort code is the one with six digits in pairs, and the account number is the eight-digit one beside it. The long number on the front of a debit card is the card number, not the account number: don’t give that to someone who wants to pay you.

What is the account name?

The account name is the name the bank holds the account in: your own name for a personal account, or the business’s registered or trading name for a business account. It’s shown in your banking app and on statements.

It matters because UK banks check it. When someone sets up a new payee, Confirmation of Payee compares the name they enter with the name on the account for that sort code and account number, before the payment is sent. The answer comes back as a match, a close match, no match (“the name is wrong”), or unavailable. Give people the account name exactly as your bank holds it, so their check comes back as a match.

What is the reference number of a bank account?

A bank account doesn’t have a separate reference number of its own. When people ask for a reference, they usually mean a payment reference: a short piece of text sent with the payment, such as an invoice number or a customer number, so the person receiving it can tell what it’s for. Banks limit how long a reference can be; the payment screen shows the limit.

Some building society savings accounts use a roll number to identify your account within a shared account. If your statement shows one, it goes in the reference when someone pays money in. When you pay a bill, use the reference the company asks for, usually your account or customer number with them.

How the IBAN fits together

A UK IBAN is built from your sort code and account number. After GB and the two check digits come four letters that identify the bank, then your 6-digit sort code, then your 8-digit account number. That makes 22 characters in all.

So if you know your sort code and account number, you can see them inside your IBAN. What you can’t safely do is make up an IBAN from them yourself: the bank code and the check digits have to be right, and only your bank can give you the correct IBAN. Find it in your banking app or on a statement (see how to find your IBAN).

A worked example: how the IBAN check digits catch mistakes

The two digits after GB are worked out from the rest of the IBAN so that a single wrong character almost always shows up. This is the check, from ISO 13616, applied to the sample IBAN GB82 WEST 1234 5698 7654 32:

  1. Move the first four characters to the end: WEST12345698765432GB82.
  2. Turn each letter into a number, A = 10 to Z = 35: W = 32, E = 14, S = 28, T = 29, G = 16, B = 11. That gives 3214282912345698765432161182.
  3. Divide that number by 97 and take the remainder. Here it is 1.

A remainder of 1 means the IBAN is correctly formed. Change the last digit from 2 to 3 and the remainder becomes 28; swap the last two digits and it becomes 49. Either way the check fails, which is how our IBAN checker can tell you about a typing mistake before you pay.

Which one to give

  • Someone paying you from a UK bank account: give your sort code and account number, and the name on the account. UK payments use these, not the IBAN.
  • Someone paying you from abroad: give your IBAN and the name on the account, and your bank’s BIC if they ask for it.
  • On an invoice: show the sort code and account number for UK customers, and add the IBAN if you have customers abroad. Our invoice generator has a place for both.

Whichever you give, include the account name exactly as your bank holds it, and a reference so you can match the payment.

What each check can and can’t tell you

An IBAN checker tests that the IBAN is correctly formed: the right length and layout for its country, and check digits that work. That catches most typing mistakes. It can’t tell you that the account exists or who holds it.

To check who holds an account, use the name check your bank runs when you set up a new payee. In the UK this is Confirmation of Payee, for payments made with a sort code and account number (Pay.UK). For euro payments, banks in the euro area must now offer a free payee verification check that does the same with an IBAN (European Commission).

If the name doesn’t match, stop and check with the person you’re paying, using contact details you already trust. Changed bank details in an email are a common sign of fraud.

Common mistakes

  • Giving the card number instead of the account number. The 16-digit number on a debit card isn’t used to pay money in.
  • Building an IBAN yourself. Use the one your bank shows; the bank code and check digits have to be right.
  • A nickname as the account name. Use the name the bank holds, or the payer’s name check may not match.
  • Leaving out the reference. Without one, matching a payment to an invoice can take far longer.

More on this topic