Contact

FLOOR.XCL Function (LibreOffice Calc)

Math Beginner LibreOffice Calc

Use FLOOR.XCL in LibreOffice Calc for legacy Excel-compatible rounding. Learn its sign-dependent direction, required step and zero-step error.

Verification status: Identified examples were recalculated through XLSX import in LibreOfficeDev 26.8.0.0.alpha0, build 2c87e51eeaa2b413ff4ae097b2705eea1995d8e5. No stable LibreOffice 25.2.3.2 or 26.8.1 execution is claimed for this guide. How formula examples are checked

Availability and version history

  • Introduced: LibreOffice 5.0, explicitly stated in official FLOOR.XCL Help.
  • Availability: Supported in LibreOffice 26.8.1.1, confirmed by the versioned function registry. This is not a final supported version.
  • Scope: Desktop Calc; formula names and separators depend on language/settings. Other spreadsheet products need separate compatibility checks.
  • Checked: October 14, 2026. Documentation/source evidence; supplementary development-build XLSX tests are scoped separately below.

At a glance

FLOOR.XCL is Calc’s legacy Excel-compatible FLOOR calculation. With a positive step it rounds downward; for a negative number, changing the step’s sign changes which side of zero the result moves toward.

=FLOOR.XCL(125;24) returns 120. Use it when your rule specifies a permitted multiple rather than a count of decimal places. Official FLOOR.XCL definition.

Syntax and arguments

=FLOOR.XCL(Number; Significance)
Argument Required Meaning
Number Yes Numeric value, cell reference or expression to round.
Significance Yes Required. Its magnitude is the step size; its sign affects negative inputs.

The XCL argument list requires both Number and Significance. Supply both arguments; there is no optional mode or third argument. The examples use English names, semicolons and decimal points. Use the separators accepted by your Calc configuration.

Reproducible examples

Formula Expected result Interpretation
=FLOOR.XCL(3.45;2) 2 Positive number and positive step.
=FLOOR.XCL(-45.67;2) -46 Negative number, positive step.
=FLOOR.XCL(-45.67;-2) -44 Negative number, negative step reverses direction.
=FLOOR.XCL(6;3) 6 Already an exact multiple.
=FLOOR.XCL(-6;3) -6 Already an exact negative multiple.
=FLOOR.XCL(1.26;0.25) 1.25 Fractional positive increment.
=FLOOR.XCL(-0.01;0.05) -0.05 Small negative input and a positive step.
=FLOOR.XCL(125;24) 120 Whole-carton quantity.
=FLOOR.XCL(0;2) 0 Zero is already a multiple.

These outputs were independently calculated with Decimal arithmetic and checked through imported XLSX recalculation in LibreOfficeDev 26.8.0.0.alpha0 (build 2c87e51eeaa2b413ff4ae097b2705eea1995d8e5). They are not direct-entry tests in the stable 26.8.1 release. For ordinary nonzero steps, think of permitted points on a number line, then select the point dictated by the sign rule. Binary floating-point boundary handling can differ from an exact decimal model for carefully chosen near-boundary inputs.

Understand negative values before copying down

For negative Number, the four legacy cases are worth making explicit:

Function/input Positive step 2 Negative step -2
CEILING.XCL(-45.67; step) -44 -46
FLOOR.XCL(-45.67; step) -46 -44

A positive Number with a negative Significance is an invalid mixed-sign case for these two XCL functions. Do not generalize from CEILING.PRECISE or the MATH variants, which ignore the step sign. A negative Number and positive Significance is valid in the XCL variants; older native Calc CEILING/FLOOR have different mixed-sign rules. Official sign rules.

Practical worksheet: complete cartons

You have 125 units available and each complete carton requires 24 units. Rounding downward gives 120 units, which fills five cartons and leaves five units unpacked. Rounding upward to 144 would allocate units you do not have.

  1. Enter 125 in A2 and 24 in B2.
  2. In C2 enter =FLOOR.XCL(A2;B2) to get 120 units.
  3. In D2 enter =C2/B2 to get 5 cartons.
  4. Keep the units in the column headings. The formula does not know whether the values represent units, metres or minutes.

The literal equivalent is included in the checked table. The cell-reference arrangement and division are reproducible worksheet instructions, not a separate claim of a saved UI session. Before filling down, decide whether zero, negative or blank quantities make sense in your operation.

Fractional increments and signed adjustments

For quarter increments, =FLOOR.XCL(1.26;0.25) gives 1.25. A quarter-step is a multiple of 0.25, not “two decimal places.” Merely formatting a cell to two decimals changes its display, not its stored number or permitted increment.

The calculation =FLOOR.XCL(-45.67;2) gives -46, but =FLOOR.XCL(-45.67;-2) gives -44. A negative step is not just decorative input. If a business configuration is supposed to specify only a positive granularity, reject negative entries rather than silently taking an absolute value and changing the intended legacy behavior.

A comparison near a step boundary should use the underlying numeric values and a tolerance appropriate to the model. Do not require a displayed rounded string to prove that two formulas are mathematically identical. If your input originated as imported text, first establish that it is a number in the intended locale.

Advanced validation pattern

If B2 must be a strictly positive step, validate it before rounding. One possible worksheet pattern is:

=IF(AND(ISNUMBER(A2);ISNUMBER(B2);B2>0);FLOOR.XCL(A2;B2);NA())

This intentionally rejects nonnumeric inputs and zero or negative steps. It is a proposed composition of documented functions, not separately executed in the native test set. The guard may be too restrictive for signed legacy models; choose validation to match the rule, rather than blindly applying it to every workbook.

For the carton example you can independently check that the rounded quantity is a multiple of 24 and lies at or below 125. Such checks catch a wrong rounding direction even when the result looks plausible. They do not certify every floating-point or error-handling edge case.

Errors and migration traps

  • Positive Number with negative Significance is an invalid sign combination under the documented XCL rules.
  • For nonzero Number, a zero step is an invalid argument in FLOOR.XCL. The release implementation explicitly rejects it; =FLOOR.XCL(3.45;0) produced Err:502 in the development-build import check. Zero Number itself returns zero before that check. Pinned implementation. Validate the step if zero is nonsensical in your model.
  • Nonnumeric inputs, missing required arguments and upstream formula errors need explicit handling. This guide does not promise one error display across every locale and version.
  • Both arguments are required, and the XCL form has no Mode argument.
  • ROUND, MROUND and ROUNDUP do different jobs. Select by direction and increment, not by a similar-looking name.

Compatibility and history

The XCL suffix identifies the legacy Excel-compatible calculation inside Calc. LibreOffice Help says that exporting FLOOR.XCL to Excel uses the name FLOOR, while importing Excel’s FLOOR uses FLOOR.XCL in Calc. Do not remove the suffix manually just because the names look similar: native Calc FLOOR has a different argument contract and mixed-sign behavior. This is documented mapping, not a claim that this audit executed an Excel round trip.

Official Help dates this function to LibreOffice 5.0 and identifies the compatibility namespace COM.MICROSOFT.FLOOR. Its statement about exclusion from the ODF 1.3 function set is scoped to that standard version. It does not mean an ODS document cannot store an extension function. Validate important workbooks in the receiving application instead of assuming that matching display names prove interoperability.

Verification and official sources

Checked October 14, 2026. Expected numerical outputs were derived independently; the stated native checks used imported OOXML formulas in the named development build. Windows/macOS, direct GUI entry, stable 26.8.1 execution and an Excel import/export round trip were not tested for this revision.