Licence plates by country — tested regexes
Every country has its own grid: series, excluded letters, banned combinations, successive formats. Each page compares a fixed regex against real attempts found online, with their real score on a test corpus.
9 countries covered.
- Belgian licence plateBelgian plate regex tested on 21 cases, compared to 3 real attempts including an npm library whose validation accepts any string (tested).
- Dutch licence plate (kenteken)Dutch kenteken regex tested on 33 cases, compared to 3 real attempts: vowels, C, Q and banned letters (SS, NSB, PVV...) pass almost everywhere.
- German licence plateGerman plate regex tested on 24 cases, compared to 3 real attempts: a leading zero and plates over 8 characters pass almost everywhere.
- Italian licence plateItalian plate regex tested on 30 cases, compared to 3 real attempts: I, O, Q, U and the skipped EE series pass almost everywhere.
- Polish licence platePolish plate regex tested on 33 cases, compared to 3 real attempts: banned letters B, D, I, O, Z and a leading zero pass almost everywhere.
- Portuguese licence platePortuguese plate regex tested on 26 cases, compared to 3 real attempts including validator.js's, which accepts '12!AB@34' (tested).
- SIV license plateSIV plate regex tested on 20 real cases, compared against 3 attempts, one of which doesn't compile in JavaScript. Real 'WW' bug found. Limits included.
- Spanish licence plate (current format)Spanish 0000 BCD plate regex tested on 22 cases, compared to 3 real attempts: one accepts vowels and Q, another any separator.
- UK vehicle registration (current format)UK AB12 CDE plate regex tested on 26 cases, compared to 3 real attempts: none checks the age identifier or the area letters.