PHP 8 compatible · Privacy focused

Calculate BIC Code from IBAN

Validate an IBAN, extract national banking identifiers, and search matching BIC records. Review every result before sending funds to any recipient.

Important limitation
A BIC is not universally calculated by formula. Reliable matching normally requires a maintained banking directory.

IBAN validation and BIC lookup

Choose a single lookup, process a batch, or inspect supported country formats.

Spaces and separators are removed automatically.
0 normalized characters
Country detection will appear here.
Plain text or the first column of pasted CSV rows is accepted.0 records
Maximum file size: 2 MB. Maximum records: 500.
Bundled countries
76
AD
SEPA

Andorra

Bank and branch codes

Length: 24
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
AD1200012030200359100100
AE
Non-SEPA

United Arab Emirates

UAE bank code

Length: 23
Bank code: BBAN positions 1–3
Branch: Not separately defined
AE070331234567890123456
AL
SEPA

Albania

Bank and branch codes

Length: 28
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–8
AL47212110090000000235698741
AT
SEPA

Austria

Bankleitzahl

Length: 20
Bank code: BBAN positions 1–5
Branch: Not separately defined
AT611904300234573201
AZ
Non-SEPA

Azerbaijan

Bank identifier

Length: 28
Bank code: BBAN positions 1–4
Branch: Not separately defined
AZ21NABZ00000000137010001944
BA
Non-SEPA

Bosnia and Herzegovina

Bank and branch codes

Length: 20
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–6
BA391290079401028494
BE
SEPA

Belgium

Bank identifier

Length: 16
Bank code: BBAN positions 1–3
Branch: Not separately defined
BE68539007547034
BG
SEPA

Bulgaria

BIC-derived bank identifier and branch

Length: 22
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
BG80BNBG96611020345678
BH
Non-SEPA

Bahrain

Bank identifier

Length: 22
Bank code: BBAN positions 1–4
Branch: Not separately defined
BH67BMAG00001299123456
BR
Non-SEPA

Brazil

Bank and branch codes

Length: 29
Bank code: BBAN positions 1–8
Branch: BBAN positions 9–13
BR1800000000141455123924100C2
BY
Non-SEPA

Belarus

Bank and balance account identifiers

Length: 28
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
BY13NBRB3600900000002Z00AB00
CH
SEPA

Switzerland

IID / clearing number

Length: 21
Bank code: BBAN positions 1–5
Branch: Not separately defined
CH9300762011623852957
CR
Non-SEPA

Costa Rica

Bank identifier

Length: 22
Bank code: BBAN positions 1–4
Branch: Not separately defined
CR05015202001026284066
CY
SEPA

Cyprus

Bank and branch codes

Length: 28
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–8
CY17002001280000001200527600
CZ
SEPA

Czechia

Bank code

Length: 24
Bank code: BBAN positions 1–4
Branch: Not separately defined
CZ6508000000192000145399
DE
SEPA

Germany

Bankleitzahl

Length: 22
Bank code: BBAN positions 1–8
Branch: Not separately defined
DE89370400440532013000
DK
SEPA

Denmark

Registration number

Length: 18
Bank code: BBAN positions 1–4
Branch: Not separately defined
DK5000400440116243
DO
Non-SEPA

Dominican Republic

Bank identifier

Length: 28
Bank code: BBAN positions 1–4
Branch: Not separately defined
DO28BAGR00000001212453611324
EE
SEPA

Estonia

Bank code

Length: 20
Bank code: BBAN positions 1–2
Branch: Not separately defined
EE382200221020145685
EG
Non-SEPA

Egypt

Bank and branch codes

Length: 29
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
EG380019000500000000263180002
ES
SEPA

Spain

Entidad and oficina

Length: 24
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
ES9121000418450200051332
FI
SEPA

Finland

Bank identifier

Length: 18
Bank code: BBAN positions 1–3
Branch: Not separately defined
FI2112345600000785
FO
SEPA

Faroe Islands

Registration number

Length: 18
Bank code: BBAN positions 1–4
Branch: Not separately defined
FO6264600001631634
FR
SEPA

France

Code banque and code guichet

Length: 27
Bank code: BBAN positions 1–5
Branch: BBAN positions 6–10
FR1420041010050500013M02606
GB
SEPA

United Kingdom

Bank identifier and sort code

Length: 22
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–10
GB29NWBK60161331926819
GE
Non-SEPA

Georgia

Bank code

Length: 22
Bank code: BBAN positions 1–2
Branch: Not separately defined
GE29NB0000000101904917
GI
SEPA

Gibraltar

Bank identifier

Length: 23
Bank code: BBAN positions 1–4
Branch: Not separately defined
GI75NWBK000000007099453
GL
SEPA

Greenland

Registration number

Length: 18
Bank code: BBAN positions 1–4
Branch: Not separately defined
GL8964710001000206
GR
SEPA

Greece

Bank and branch codes

Length: 27
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–7
GR1601101250000000012300695
GT
Non-SEPA

Guatemala

Bank and branch identifiers

Length: 28
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
GT82TRAJ01020000001210029690
HR
SEPA

Croatia

Bank identifier

Length: 21
Bank code: BBAN positions 1–7
Branch: Not separately defined
HR1210010051863000160
HU
SEPA

Hungary

Bank and branch codes

Length: 28
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–7
HU42117730161111101800000000
IE
SEPA

Ireland

Bank identifier and sort code

Length: 22
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–10
IE29AIBK93115212345678
IL
Non-SEPA

Israel

Bank and branch codes

Length: 23
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–6
IL620108000000099999999
IQ
Non-SEPA

Iraq

Bank and branch identifiers

Length: 23
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–7
IQ98NBIQ850123456789012
IS
SEPA

Iceland

Bank identifier

Length: 26
Bank code: BBAN positions 1–4
Branch: Not separately defined
IS140159260076545510730339
IT
SEPA

Italy

ABI and CAB

Length: 27
Bank code: BBAN positions 2–6
Branch: BBAN positions 7–11
IT60X0542811101000000123456
JO
Non-SEPA

Jordan

Bank and branch identifiers

Length: 30
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
JO94CBJO0010000000000131000302
KW
Non-SEPA

Kuwait

Bank identifier

Length: 30
Bank code: BBAN positions 1–4
Branch: Not separately defined
KW81CBKU0000000000001234560101
KZ
Non-SEPA

Kazakhstan

Bank identifier

Length: 20
Bank code: BBAN positions 1–3
Branch: Not separately defined
KZ86125KZT5004100100
LB
Non-SEPA

Lebanon

Bank identifier

Length: 28
Bank code: BBAN positions 1–4
Branch: Not separately defined
LB62099900000001001901229114
LC
Non-SEPA

Saint Lucia

Bank identifier

Length: 32
Bank code: BBAN positions 1–4
Branch: Not separately defined
LC55HEMM000100010012001200023015
LI
SEPA

Liechtenstein

Bank identifier

Length: 21
Bank code: BBAN positions 1–5
Branch: Not separately defined
LI21088100002324013AA
LT
SEPA

Lithuania

Bank code

Length: 20
Bank code: BBAN positions 1–5
Branch: Not separately defined
LT121000011101001000
LU
SEPA

Luxembourg

Bank code

Length: 20
Bank code: BBAN positions 1–3
Branch: Not separately defined
LU280019400644750000
LV
SEPA

Latvia

Bank identifier

Length: 21
Bank code: BBAN positions 1–4
Branch: Not separately defined
LV80BANK0000435195001
MC
SEPA

Monaco

Code banque and code guichet

Length: 27
Bank code: BBAN positions 1–5
Branch: BBAN positions 6–10
MC5810096180790123456789085
MD
Non-SEPA

Moldova

Bank identifier

Length: 24
Bank code: BBAN positions 1–2
Branch: Not separately defined
MD24AG000225100013104168
ME
SEPA

Montenegro

Bank and branch codes

Length: 22
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–6
ME25505000012345678951
MK
Non-SEPA

North Macedonia

Bank identifier

Length: 19
Bank code: BBAN positions 1–3
Branch: Not separately defined
MK07250120000058984
MT
SEPA

Malta

Bank and branch identifiers

Length: 31
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–9
MT84MALT011000012345MTLCAST001S
MU
Non-SEPA

Mauritius

Bank and branch identifiers

Length: 30
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–6
MU17BOMM0101101030300200000MUR
NL
SEPA

Netherlands

Bank identifier

Length: 18
Bank code: BBAN positions 1–4
Branch: Not separately defined
NL91ABNA0417164300
NO
SEPA

Norway

Bank registration number

Length: 15
Bank code: BBAN positions 1–4
Branch: Not separately defined
NO9386011117947
PK
Non-SEPA

Pakistan

Bank identifier

Length: 24
Bank code: BBAN positions 1–4
Branch: Not separately defined
PK36SCBL0000001123456702
PL
SEPA

Poland

National clearing number

Length: 28
Bank code: BBAN positions 1–8
Branch: Not separately defined
PL61109010140000071219812874
PS
Non-SEPA

Palestine

Bank identifier

Length: 29
Bank code: BBAN positions 1–4
Branch: Not separately defined
PS92PALS000000000400123456702
PT
SEPA

Portugal

Bank and branch codes

Length: 25
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–8
PT50000201231234567890154
QA
Non-SEPA

Qatar

Bank identifier

Length: 29
Bank code: BBAN positions 1–4
Branch: Not separately defined
QA58DOHB00001234567890ABCDEFG
RO
SEPA

Romania

Bank identifier

Length: 24
Bank code: BBAN positions 1–4
Branch: Not separately defined
RO49AAAA1B31007593840000
RS
Non-SEPA

Serbia

Bank and branch codes

Length: 22
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–6
RS35260005601001611379
SA
Non-SEPA

Saudi Arabia

Bank code

Length: 24
Bank code: BBAN positions 1–2
Branch: Not separately defined
SA0380000000608010167519
SC
Non-SEPA

Seychelles

Bank and branch identifiers

Length: 31
Bank code: BBAN positions 1–4
Branch: BBAN positions 5–6
SC18SSCB11010000000000001497USD
SE
SEPA

Sweden

Bank identifier

Length: 24
Bank code: BBAN positions 1–3
Branch: Not separately defined
SE4550000000058398257466
SI
SEPA

Slovenia

Bank identifier

Length: 19
Bank code: BBAN positions 1–5
Branch: Not separately defined
SI56263300012039086
SK
SEPA

Slovakia

Bank code

Length: 24
Bank code: BBAN positions 1–4
Branch: Not separately defined
SK3112000000198742637541
SM
SEPA

San Marino

ABI and CAB

Length: 27
Bank code: BBAN positions 2–6
Branch: BBAN positions 7–11
SM86U0322509800000000270100
ST
Non-SEPA

São Tomé and Príncipe

Bank and branch identifiers

Length: 25
Bank code: BBAN positions 1–8
Branch: BBAN positions 9–12
ST68000100010051845310112
SV
Non-SEPA

El Salvador

Bank identifier

Length: 28
Bank code: BBAN positions 1–4
Branch: Not separately defined
SV62CENR00000000000000700025
TL
Non-SEPA

Timor-Leste

Bank and branch codes

Length: 23
Bank code: BBAN positions 1–3
Branch: BBAN positions 4–6
TL380080012345678910157
TN
Non-SEPA

Tunisia

Bank and branch codes

Length: 24
Bank code: BBAN positions 1–2
Branch: BBAN positions 3–5
TN5910006035183598478831
TR
Non-SEPA

Türkiye

Bank and reserve/branch identifiers

Length: 26
Bank code: BBAN positions 1–5
Branch: BBAN positions 7–10
TR330006100519786457841326
UA
Non-SEPA

Ukraine

Bank code

Length: 29
Bank code: BBAN positions 1–6
Branch: Not separately defined
UA213223130000026007233566001
VA
SEPA

Vatican City

Bank identifier

Length: 22
Bank code: BBAN positions 1–3
Branch: Not separately defined
VA59001123000012345678
VG
Non-SEPA

British Virgin Islands

Bank identifier

Length: 24
Bank code: BBAN positions 1–4
Branch: Not separately defined
VG96VPVG0000012345678901
XK
SEPA

Kosovo

Bank identifier

Length: 20
Bank code: BBAN positions 1–4
Branch: Not separately defined
XK051212012345678906

JSON validation endpoint

Send a POST request to ?api=1 with a JSON body. The endpoint returns validation details, extracted identifiers, directory matches, and BIC structure checks.

{
  "iban": "DE89370400440532013000",
  "lookup_mode": "branch"
}

Health check

Open ?health=1 to inspect runtime status, PHP version, directory version, supported country count, and remote API configuration.

Remote API lookup is currently disabled. Configure the constants at the top of this file for a licensed provider.
Production integration requirement: Adapt remoteBicLookup() to your provider's authentication, request schema, rate limits, response structure, licensing terms, and retention policy. Never expose API keys in browser-side JavaScript.
1

How to use this calculator

  1. Paste or type the complete IBAN.
  2. Select bank-level or branch-level matching.
  3. Choose compact or detailed results.
  4. Submit the form and review every validation check.
  5. Confirm the returned BIC with the receiving bank.
2

Formula used

The IBAN checksum uses MOD-97. The first four characters move to the end. Letters become numbers from A=10 through Z=35. The resulting large number must leave a remainder of 1 when divided by 97.

remainder(rearranged IBAN ÷ 97) = 1
3

What the lookup really does

The application extracts the country-specific national bank code and optional branch code. It then compares those identifiers with directory records. This is a reference-data lookup, not a universal mathematical conversion.

Understanding IBAN and BIC results

An International Bank Account Number provides a standardized way to represent a bank account across participating countries. The first two characters identify the country. The next two digits are checksum digits. The remaining portion is the Basic Bank Account Number, or BBAN. Each country defines its own BBAN layout. That layout can contain a bank code, branch code, domestic checksum, account number, and other national identifiers.

Why the BIC cannot always be calculated

A Business Identifier Code identifies a financial or non-financial institution. It has eight required characters and may include a three-character branch identifier. Some countries place a recognizable bank identifier inside the IBAN. Other countries use numeric clearing codes. A maintained directory is still needed to map those national identifiers to the correct institution record. Banks can merge, rebrand, close branches, change routing arrangements, or use several BICs. For that reason, a fixed formula cannot guarantee a current answer.

What a valid checksum proves

A successful MOD-97 test confirms that the IBAN is internally consistent. It helps detect many typing and transposition errors. It does not prove that the account exists. It does not confirm the beneficiary name. It does not prove that the bank accepts the intended currency or payment method. It also does not guarantee that a BIC directory record is current. Treat validation as one part of a broader payment-verification process.

Eight-character and eleven-character BICs

The first four BIC characters identify the institution. The next two indicate the country. The following two form the location code. An optional final three-character branch code may identify a branch, department, or service. An eight-character BIC generally represents the primary office or institution level. Some systems display an eleven-character form ending in XXX. That convention should never be added silently when the directory does not explicitly provide it.

Branch-level ambiguity

A national branch or clearing code may map to one BIC, several BICs, or no public BIC. Centralized payment processing can also cause multiple branches to share one institution-level BIC. This calculator first tries a branch-level key when the country format includes a branch code. It then falls back to a bank-level key. The result panel explains which key produced the match.

Privacy and safe handling

IBANs should be treated as financial identifiers. This page masks account characters by default. It does not place submitted IBANs in URLs. It applies a no-index directive to discourage search-engine storage of result pages. The example implementation also avoids persistent server-side logging. A production deployment should use HTTPS, strict access controls, secure backups, limited retention, and a documented deletion policy. Any remote directory provider should be disclosed before data is transmitted.

Batch processing

The batch tool accepts one IBAN per line or the first column of a CSV or text file. It can remove duplicates and process up to 500 records per request. Each row reports validity, extracted bank and branch codes, the first directory match, and any validation issue. Downloaded CSV values receive basic spreadsheet-formula protection. Large commercial workflows should use authenticated APIs, queues, monitoring, and licensed reference data.

Final verification

Always compare payment instructions through an independent channel. Contact the beneficiary using a trusted phone number or established business contact. Be cautious when bank details change unexpectedly. Do not rely on email alone for high-value payments. This calculator is an identifier-analysis tool. It is not a substitute for bank confirmation, beneficiary verification, fraud screening, sanctions screening, or professional compliance review.

Included technical safeguards

  • Strict PHP typing and output escaping.
  • CSRF protection for browser forms and exports.
  • Session-based request limiting.
  • Secure response headers and a restrictive content policy.
  • CSV/TXT extension checks and a 2 MB limit.
  • No complete IBAN in exported page URLs.
  • Spreadsheet-formula prefix protection in CSV exports.
  • Optional server-side remote directory integration.

Deployment checklist

  • Replace demonstration records with licensed data.
  • Confirm all country layouts against current registry rules.
  • Use HTTPS and disable verbose production errors.
  • Store API secrets outside the web root.
  • Set realistic rate limits and monitor abuse.
  • Document data retention and third-party processing.
  • Test with valid, invalid, and boundary IBAN examples.
  • Obtain legal and compliance review where required.

Related Calculators

Average Calculator StatisticsGeometric Mean CalculatorInter Quartile Range CalculatorLower Quartile CalculatorMaximum CalculatorMean Calculator StatisticsMedian Calculator StatisticsMidhinge Calculator StatisticsMid Range Calculator StatisticsMode Calculator Statistics

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.