ARABIC Function (LibreOffice Calc)
Convert Roman numerals with LibreOffice ARABIC, including lowercase and simplified forms, empty-string zero, invalid-text errors and strict-style validation.
Verification status: Eight reference formulas and 8 diagnostic cases were recalculated through XLSX import in LibreOfficeDev 26.8.0.0.alpha0, build 2c87e51eeaa2b413ff4ae097b2705eea1995d8e5. This is headless development-build evidence. The original single-example ledger separately records ARABIC("XIV")=14 in LibreOffice 25.2.3.2. How formula examples are checked
Availability and version history
- Introduced: Documented by LibreOffice 26.8.1.1; original introduction not established.
- Availability: Supported in LibreOffice 26.8.1.1, verified against its function registry. This identifies a supported release, not a final working version.
- Scope: Desktop Calc, using the English function name. Availability in other spreadsheet applications is separate.
- Checked: 2026-10-14 — function reference; versioned support. Release availability is source-checked. The native examples below have their own named build and test scope.
Quick answer: =ARABIC("IV") returns 4.
What ARABIC returns
ARABIC converts Roman-numeral text to a number. It accepts uppercase and lowercase Roman letters and supports several simplified representations in addition to familiar classical notation. For example, both CDXCIX and LDVLIV represent 499 in the inspected Calc implementation. It is a numeral parser, not a general-purpose conversion of decimal text. See the official function reference and pinned LibreOffice calculation routine.
Syntax and arguments
=ARABIC(Text)
Supply one text argument, either a quoted numeral or a cell reference. The parser converts ASCII letters to uppercase, then checks their order and remaining permitted value. Accepted nonempty examples represent positive integers up to 3999; an empty string has the special result zero. The digit character “0” is not a Roman numeral and produces an invalid-argument error.
Eight reproducible examples
These formulas were recalculated through XLSX import in LibreOfficeDev 26.8.0.0.alpha0, build 2c87e51eeaa2b413ff4ae097b2705eea1995d8e5. Their saved results agree with independent calculations. ARABIC results are numbers. This headless run does not establish stable-release or GUI behavior.
| Formula | Result |
|---|---|
=ARABIC("I") |
1 |
=ARABIC("IV") |
4 |
=ARABIC("IX") |
9 |
=ARABIC("XLII") |
42 |
=ARABIC("XCIX") |
99 |
=ARABIC("MMXXVI") |
2026 |
=ARABIC("MMMCMXCIX") |
3999 |
=ARABIC("mcmxcix") |
1999 |
Practical worksheet
Sort Roman-numbered pages numerically
Put the original page labels in A2:A10 and enter =ARABIC(A2) in B2, then fill down. The helper numbers sort I, II, IV, IX and X by their numeric values instead of alphabetically. Keep the original label alongside the helper so the displayed page notation is not lost.
If a blank label means missing data, use =IF(A2="";"Missing";IFERROR(ARABIC(A2);"Invalid numeral")). This explicitly separates an absent label from a parsed number and an invalid string. Do not silently substitute zero for every error.
Normalize accepted variants
For accepted nonempty input, =ROMAN(ARABIC(A2)) returns Calc’s default classical spelling of the parsed value. With LDVLIV it returns CDXCIX; with IIII it returns IV. This can standardize a display column without overwriting the source text. The normalization changes the spelling, not the numeric interpretation.
Advanced interpretation
Parsing success does not prove classical spelling
=ARABIC("IL") produces 49 and =ARABIC("IIII") produces 4 in the checked build. A test that merely asks whether ARABIC returns a number therefore accepts more than strict classical Roman notation. On the other hand, not every arbitrary string of Roman letters works: VV and MMMM produce errors.
If your rule is “the default classical spelling, ignoring letter case,” compare the original label with a round trip:
=IF(A2="";FALSE();IFERROR(EXACT(UPPER(A2);ROMAN(ARABIC(A2)));FALSE()))
For XIV or xiv, the comparison is TRUE. For IIII or IL, it is FALSE because the default spellings are IV and XLIX. This is a clearly defined normalization check; it is not a universal test of every historical Roman-writing convention. The outer blank check matters because the parser’s empty-string result is zero.
Keep text cleaning explicit
The inspected ARABIC routine does not trim spaces before parsing. If your import process permits stripping surrounding spaces, apply that as a separate cleaning step and retain the original column for review. Do not remove every non-Roman character indiscriminately: that could turn an invalid label or annotation into a different valid numeral.
Boundaries and troubleshooting
An empty string and the character “0” behave differently: the former returns 0, while the latter errors. Repeated symbols and subtractive combinations are constrained by the parser; simplified notation is supported, but that is not a promise that every malformed arrangement will be accepted. Negative signs, punctuation and ordinary decimal digits are not Roman numeral symbols.
Development-build checks
These additional cases were saved from the same recalculation. Error displays remain errors, not successful zero values.
| Formula | Native result or error |
|---|---|
=ARABIC("XIV") |
14 |
=ARABIC("LDVLIV") |
499 |
=ARABIC("0") |
Err:502 |
=ARABIC("") |
0 |
=ARABIC("IL") |
49 |
=ARABIC("IIII") |
4 |
=ARABIC("VV") |
Err:502 |
=ARABIC("MMMM") |
Err:502 |
Related functions
Evidence and checking scope
The LibreOffice 26.8.1.1 source establishes the inspected parser and argument rules. Native execution covers the eight reference formulas and listed diagnostics only in the named development build. A deliberately stale SUM cache changed from 999999 to 3, and an uncached SUM returned 7 after forced recalculation. Composite worksheet examples were independently checked; no broader stable-release, GUI or extreme-input test is inferred.
Reproducible example (tested in LibreOffice Calc)
This standalone example was calculated in LibreOffice Calc 25.2.3.2 and matched the expected value. It is a practical cross-check of one usage, not proof that every example elsewhere on this page is correct.
=ARABIC("XIV")
Expected result: 14.
Convert a Roman numeral into an ordinary number.
If the result differs, check the referenced cells, argument separators and number formatting. For more information, consult the LibreOffice Calc official help.
This older single-example result is retained from the original test ledger. It was not rerun in that stable release, and it does not extend the development-build checks to LibreOffice 25.2.3.2.