Database
DCOUNTA Function in Excel
Counts non-blank cells in a database that match specified criteria.
Syntax
- =DCOUNTA(database, field, criteria)
Arguments
- database (required): Range including headers
- field (required): Column to count (name or number)
- criteria (required): Range with criteria headers and values
Examples
- =DCOUNTA(A1:D10, "Name", F1:F2) - Count non-blank entries - Result: Count
D-functions vs DCOUNTA
- Database functions use a criteria range with headers matching your list.
- For simple AND criteria [SUMIFS](/functions/sumifs/) may be easier to audit.
- Compare [SUMIF vs SUMIFS](/compare/sumif-vs-sumifs/) for reporting patterns.
Common errors
- Counts text and numbers
Use cases
- Count all entries
- Database analysis
- Non-blank counting
Frequently asked questions
- What is the DCOUNTA function in Excel? DCOUNTA counts non-blank cells in a database that match specified criteria. The syntax is =DCOUNTA(database, field, criteria). Typical use cases include count all entries, database analysis, non-blank counting.
- How do I use the DCOUNTA function? To use DCOUNTA, type =DCOUNTA( in a cell and provide the required arguments. Excel will show you the syntax and parameter hints as you type. Make sure to close the parentheses and press Enter to execute the function.
- Why is DCOUNTA not working in my Excel? Common issues with DCOUNTA include Counts text and numbers. Start by checking the syntax =DCOUNTA(database, field, criteria), then verify each referenced cell or range.
Editorial review
- Reviewed by Excel.Directory Editorial Team. Updated May 2026.