Test IBAN for Spain — valid ES IBANs for development and QA

Spain (ES) - IBAN length: 24 characters, SEPA member, domestic check digit validated.

For developers and QA. Uses documented test/example bank codes where available. Never use a generated IBAN for a real payment.

Spanish bank details carried a national checksum long before IBANs existed, and that history still shapes what a correct test IBAN for Spain must look like. The ES IBAN is 24 characters: ES, two ISO mod-97 check digits, then a fully numeric 20-digit BBAN made of a 4-digit bank code (entidad), a 4-digit branch code (oficina), two national control digits (dígitos de control, the old CCC checksum) and a 10-digit account number.

Two checksums, two ways to fail

Most generic validators only verify the mod-97 check digits after ES. Spanish banks and stricter libraries also recompute the two dígitos de control using the traditional weighted algorithm over the entity, office and account fields. If your fixtures only satisfy the outer check, they will pass your CI and then fail the first time a Spanish acquirer or a thorough backend validates the inner one. The generator on this page computes both layers, so the output holds up under either level of scrutiny.

Where this saves you time

Think of a Playwright suite for a Spanish e-commerce checkout with SEPA Direct Debit: the test has to type an IBAN into the mandate form, and the form validates on blur. With a structurally valid ES IBAN the test exercises the real success path, the confirmation screen, and the mandate-created webhook in your sandbox. The same generated values work for unit tests of your own validation code, for seeding staging databases with Spanish customer records, and for reproducing region-specific bugs without borrowing anyone’s real cuenta.

Generation happens entirely in your browser. No value is sent anywhere, and every IBAN is stamped with a TEST label so screenshots and bug reports stay unambiguous.

Use it for testing, nothing else

A passing checksum says the string is well-formed, not that an account exists behind it. These IBANs are for software testing, demos and documentation. Using them on an invoice, in a payment request, or to misrepresent bank details is misuse, and EU Verification of Payee name-matching will flag such payments anyway.

Frequently asked questions

How many characters does a Spanish IBAN have?

24. It starts with ES and two check digits, followed by a 20-digit BBAN: 4-digit bank code, 4-digit branch code, 2 national control digits (dígitos de control) and a 10-digit account number.

What are the dígitos de control?

Two national check digits inside the Spanish BBAN, computed with a weighted algorithm over the bank/branch codes and the account number. They predate the IBAN and are validated separately from the IBAN's mod-97 check.

Can a valid-looking ES test IBAN receive real money?

No. Generated IBANs pass format and checksum tests but correspond to no actual account. Banks additionally verify payee names under EU Verification of Payee rules, so they cannot be used for real transfers.

Related: Spain IBAN format ·how mod-97 check digits work ·all test IBAN countries

Data source: ISO 13616 IBAN Registry Release 102 (June 2026). Last verified: 2026-07-05.