Contact

COUNT Function (LibreOffice Calc)

Math Beginner LibreOffice Calc Introduction not established

The COUNT function in LibreOffice Calc counts numeric values in a range or list of arguments. This guide explains syntax, examples, edge cases, errors, and best practices.

Verification status: Consult the documentation, examples and any stated test scope below. 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. Documentation/source check; not a new native test. Existing example-specific test claims below retain their stated scope.
The **COUNT** function returns the number of cells containing numeric values. It is one of the most fundamental data‑analysis tools in LibreOffice Calc, used for validating datasets, summarizing numeric entries, and preparing data for statistical or financial calculations.

What the COUNT Function Does

  • Counts numeric values
  • Ignores text, empty cells, and logical values
  • Works with ranges, references, and mixed arguments
  • Supports multiple ranges in a single formula
  • Works across sheets
  • Handles large datasets efficiently

COUNT is ideal for determining how many valid numeric entries exist in a dataset.

Syntax

COUNT(value1; value2; ...)
LibreOffice Calc uses semicolons (;) to separate arguments, not commas.
COUNT only counts numbers. To count text, use COUNTA. To count blank cells, use COUNTBLANK.

Basic Examples

Count numbers in a range

=COUNT(A1:A10)

Counts how many cells in A1 through A10 contain numeric values.

Count numbers in multiple ranges

=COUNT(A1:A10; C1:C10)

Useful when numeric data is separated into blocks.

Count specific values

=COUNT(5; 12; "text"; 19)

Result: 3 (text is ignored)

Count mixed references and values

=COUNT(A1:A10; 25; C5)
COUNT can accept up to 255 arguments, including ranges, values, and references.

Advanced Examples

Count numbers across sheets

=COUNT(Sheet1.A1:A10; Sheet2.B1:B10)

Count numbers using 3D references

LibreOffice supports 3D ranges:

=COUNT(Sheet1:Sheet5.A1)

Counts how many of the A1 cells across five sheets contain numbers.

Count only visible cells (filtered data)

LibreOffice Calc does not have a COUNTVISIBLE function, but you can use:

=SUBTOTAL(102; A1:A10)

Function code 102 means COUNT.

Count numbers with conditions (COUNTIF)

=COUNTIF(A1:A10; ">50")

Counts how many values in A1:A10 are greater than 50.

Count numbers with multiple conditions (COUNTIFS)

=COUNTIFS(A1:A100; "North"; B1:B100; ">1000")

Common Errors and Fixes

COUNT returns 0 unexpectedly

Possible causes:

  • Cells contain text instead of numbers
  • Numbers stored as text (common in imported CSV files)
  • Hidden apostrophes ('123)
  • Formulas returning text instead of numbers

Fix: Convert text to numbers:
Data → Text to Columns → OK

Err:504 — Parameter error

Occurs when:

  • A range reference is malformed
  • A non‑range argument is incorrectly formatted

COUNT ignores logical values (TRUE/FALSE)

This is expected behavior.
Use COUNTIF or SUMPRODUCT if you need to count logical values.

Best Practices

  • Use COUNT when you only want to count numeric values
  • Use COUNTA to count non‑empty cells
  • Use COUNTBLANK to count empty cells
  • Use COUNTIFS for multi‑condition counting
  • Convert imported text‑numbers to real numbers before analysis
  • Use named ranges for cleaner formulas
Named ranges make formulas easier to read and maintain.
Example: =COUNT(Sales_Entries)

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.

=COUNT(3;5;7)

Expected result: 3.

Count numeric arguments without counting their sum.

If the result differs, check the referenced cells, argument separators and number formatting. For more information, consult the LibreOffice Calc official help.