CEILING
Supported, behaves as documentedCategory: Compatibility · Last tested 2026-07-04
Support matrix
| Engine | Documented | Live-tested | Verdict |
|---|---|---|---|
| Excel | Yes | Not yet | n/a |
| Google Sheets | Yes | Not yet | n/a |
| LibreOffice Calc | No | Yes (24.2.7.2, 2026-07-04) | Supported, behaves as documented |
Executed test cases
LibreOffice Calc 24.2.7.2 (tested 2026-07-04)
| Formula | Description | Result | Expected | Verdict |
|---|---|---|---|---|
| =CEILING(2.5,1) | Basic case, rounds 2.5 up to the nearest multiple of 1. Source: https://support.microsoft.com/en-us/office/ceiling-function-0a5cd7c8-0720-4f0a-bd2c-c943e510899f (worked example table) | 3 | 3 | Matched |
| =CEILING(0.234,0.01) | Rounds 0.234 up to the nearest multiple of 0.01. Source: Microsoft CEILING docs worked example table. | 0.24 | 0.24 | Matched |
| =CEILING(-2.5,-2) | Number and significance both negative -> rounds away from zero (more negative), per Microsoft's documented rule and worked example. | -4 | -4 Microsoft: 'If number is negative, and significance is negative, the value is rounded down, away from zero.' Worked example CEILING(-2.5,-2)=-4 at https://support.microsoft.com/en-us/office/ceiling-function-0a5cd7c8-0720-4f0a-bd2c-c943e510899f |
Matched |
| =CEILING(-2.5,2) | Number negative, significance positive -> rounds up toward zero (less negative), per Microsoft's documented rule and worked example. | -2 | -2 Microsoft: 'If number is negative, and significance is positive, the value is rounded up towards zero.' Worked example CEILING(-2.5,2)=-2 at the same doc page. |
Matched |
| =CEILING(-45.67,-2) | GOLD QUIRK CANDIDATE: identical 2-argument call (Mode omitted) with number and significance both negative. Per Microsoft's documented CEILING rule this must round AWAY from zero. | -46 | -46 Microsoft (https://support.microsoft.com/en-us/office/ceiling-function-0a5cd7c8-0720-4f0a-bd2c-c943e510899f): both-negative case rounds away from zero, so CEILING(-45.67,-2) -> -46 (ratio -45.67/-2=22.835, ceiling(22.835)=23, 23*-2=-46). LibreOffice's own CEILING docs (https://help.libreoffice.org/latest/en-US/text/scalc/01/func_ceiling.html) define a 3rd optional Mode argument that ONLY applies when both Number and Significance are negative, and state: 'if Mode is equal to zero or not given, negative numbers are rounded up (towards zero)' -- with LO's own worked example CEILING(-45.67;-2;0) = -44. That means the identical 2-arg formula (Mode omitted) is documented to resolve to -44 under LibreOffice's own default, vs -46 under Microsoft's documented default -- a genuine cross-engine default-behavior divergence for the exact same formula text, not just a wording difference. If LO's executed result is -44, matched_expected:false here is the intended, correct signal of that divergence -- do not 'fix' this expectation to match LO. |
Matched |
| =CEILING("abc",1) | Nonnumeric first argument -> #VALUE!, per Microsoft docs: 'If either argument is nonnumeric, CEILING returns the #VALUE! error value.' | #VALUE! | #VALUE! | Matched |
Docs & syntax
- Excel: official documentation
- Google Sheets: official documentation