Skip to content
Math & Statisticsnotation

Roman Numeral Converter

Roman numerals in both directions, using the six standard subtractive pairs and the conventional 1–3999 range.

Also called: roman numerals to numbers, number to roman numerals.

Type 2026 or MMXXVI. It works both ways.

Converted
MMXXVI

2026 is MMXXVI.

Method and background

How this is calculated

Greedy matching against a table that includes the subtractive pairs (CM, CD, XC, XL, IX, IV) alongside the plain symbols. The upper limit of 3999 is the conventional one: there is no standard single-character symbol for 5000, and the overline notation is not text.

standard additive notation with six subtractive pairs
M, D, C, L, X, V, I
The seven symbols

Worked examples

Each of these is asserted on every build. If a change to the engine ever moved one of these answers, the build would fail before the page could print it.

2026 to numerals

Number or numeral
2026

ConvertedMMXXVI

standard additive notation

Open this example

numerals back to a number

Number or numeral
MCMXCIV

Converted1994

the canonical subtractive-pair example

Open this example

out of range

Number or numeral
4000

ConvertedRoman numerals conventionally run from 1 to 3999.

boundary

Open this example