In some cases, the first digit of the sort code identifies the bank itself and in other cases the first 2 digits identify the bank.
The underlying rules for IBANs is that the account-servicing financial institution should issue an IBAN, as there are a number of areas where different IBANs could be generated from the same account and branch numbers that would satisfy the generic IBAN validation rules. The British and Irish sort codes are only used for domestic money transfers. The numbering ranges for both are complementary, but do not overlap.
The SORT Codes database can be integrated in any software system or used as a standalone reference file for verifying banking transactions.
Although there is a strong correlation between BIC Codes and sort codes, sort codes are not explicitly encoded into BIC codes (although they are encoded into IBANs).