IBAN format · SM
Sammarinese IBAN format
The Sammarinese IBAN format is defined by ISO 13616 and is fixed for every account opened in San Marino. A Sammarinese IBAN is always 27 characters long and uses the structure pattern 1!a5!n5!n12!c: 1 letter (A–Z), then 5 digits (0–9), then 5 digits (0–9), then 12 characters (A–Z, 0–9). The first two characters are the country code SM, the next two are MOD 97 check digits, and the remaining 23 characters form the BBAN, which San Marino divides into 4 fields. This page breaks down each field, shows a worked SM IBAN, and explains how the check digits are computed.
Structure breakdown
The San Marino BBAN (positions 5–27) is the country-specific part of the IBAN and is 23 characters long. San Marino splits it into 4 fields: Field 1 is 1 letter; Field 2 is 5 digits; Field 3 is 5 digits; Field 4 is 12 characters. The exact meaning of each field (bank code, branch, account number) is defined by San Marino's national registry and is stable, so a SM IBAN that matches the pattern and length is structurally valid even before the MOD 97 check.
The table below applies the 1!a5!n5!n12!c pattern to a real, MOD 97-valid San Marino IBAN (SM68A0123401234ABCD1234EFGH). Each row shows one field of the IBAN — country code, check digits, then the BBAN fields in order — so you can see exactly how a SM IBAN is assembled. This is the same breakdown the IBAN validator produces when you paste a San Marino IBAN.
Sammarinese IBAN check digits
Positions 3–4 of a San Marino IBAN hold two MOD 97-10 check digits. ISO 13616 computes them by rearranging the IBAN so the BBAN leads and the country code plus check digits trail, converting letters to numbers (A=10 … Z=35), and taking the giant resulting integer mod 97. The check digits are chosen so the whole IBAN leaves a remainder of 1. If any single character of a SM IBAN is mistyped, the remainder changes and validation fails — which is why the format checker on this page can flag a typo from one wrong digit.
What makes a Sammarinese IBAN valid
A San Marino IBAN is structurally valid only when it passes three independent checks at once. First, the character set: the first two characters must be the letters SM, the next two must be digits, and the BBAN may contain only digits and uppercase letters. Second, the length: a SM IBAN must be exactly 27 characters, because San Marino fixes its BBAN at 23 characters and ISO 13616 fixes the country code and check digits at four. Third, the MOD 97 checksum. The 1!a5!n5!n12!c pattern adds one more layer — it confirms the BBAN splits into 4 fields of the right size and type, so a San Marino IBAN with the right total length but the wrong internal split still fails. This is why the format checker on this page is stricter than a generic length-only check.
Common Sammarinese IBAN format mistakes
Most San Marino IBAN format errors come from a handful of avoidable mistakes. Pasting a domestic San Marino account number instead of the IBAN is the most common — the IBAN always starts with SM and is 27 characters, while a local account number is usually shorter and has no country prefix. Dropping or adding a character when copying from a statement is next; because the length is fixed, even one extra digit fails. Confusing the country code with a similar one (for example SM vs a neighbor) changes both the expected length and the check digits, so the whole IBAN fails. Finally, including spaces in the stored value is harmless for validation but can break payment forms that count characters literally — strip spaces before you submit a SM IBAN to a wire form.
Sammarinese IBAN and SWIFT codes
When you send or receive an international payment to San Marino, the IBAN tells the network which account to credit, and the bank's SWIFT/BIC code tells it which bank holds that account. After checking the SM IBAN format here, look up the receiving bank's BIC with a SWIFT code lookup tool to complete the wire instructions.