How do I check a bank account number is correct?

Read time: 3 mins

Each bank account number in the UK and Ireland is generated using an algorithm unique to that bank (and sometimes each branch within a bank). Bank account numbers are not generated sequentially, and the system used to generate them is designed to prevent account numbers from having similarity that can result in money being sent to the wrong account.

For example, a branch could generate an account number of "12345678" but would not generate an account number "12354678".

Bank Account & Sort Code Checker

Try our service for free

Sign up for a free trial to get

  • Unlimited checks
  • Sort code, account, SWIFT and IBAN validation
  • All branch data and supported payment types

Want to automate these checks? Discover how to automate your account checking

How does it work?

Banks use a combination of "modulo" and "double-alternate" algorithms, along with a set of "weights" to perform a mathematical calculation - all designed to help identify when account numbers have been entered incorrectly. The most common types of mistake are when numbers are swapped and these types of algorithms help identify that.

As new banks open and sort codes are issued, the algorithms for these banks need to be published and shared with banks. Mintly is constantly keeping its system updated with these new algorithms, so our customers have access to the latest data.

There are several ways to check an account number and sort code are valid. One is to obtain the directory of sort codes, and then implement the algorithms and weight database needed to perform the checks. This database then needs to be updated regularly whenever new data or algorithms are issued. To check a bank sort code is valid, you can use a lookup table and keep this table updated as the data changes.

Alternatively you can use a system like Mintly. Our database is updated weekly with the newest data and algorithms, and our stable API allows you to query a sort code, and account number. We'll tell you if it's valid and the types of payment that the branch supports. We make it really easy to integrate with existing systems too.

Lady checking a debit card account number

Need a solution for your business?

If you're looking for an online sort code and account number checker then our online portal can give you unlimited checks. Or use our free sort code checker tool where you can check 10 accounts a day totally free! If you need a sort code checker for faster payments, BACS or Direct Debit then Mintly tools can help you.

To use our bank sort code and account number checker, you can login to our portal and submit the details; our fast service returns the answer and tells you the name, location and contact details of the bank branch based on the sorting code, and tells you whether it is a valid bank account. Note that the algorithms used can only say whether an account number is valid or not; the account number may not be in use.

To watch a short video that showcases our tools, click here

Automation - the next step

For businesses wanting to automate their processes and integrate a sort code check or bank account check into their own systems, Mintly offers an API (Application Programming Interface) that allows systems to talk to each other over the internet securely. Our API sends back all the bank details once validated, so that you can handle the next step in your workflow.

If you'd like to try Mintly out, we have a 14 day free trial for all our plans, or if you have further questions, please get in touch, we'd love to help you with your bank validation needs.