Workflow guide
Google Sheets QUERY vs FILTER
Use this workflow guide when you know you need filtered rows, but you are not sure whether QUERY or FILTER is the cleaner formula for the job.
Which formula should you use?
| Situation | Use | Why |
|---|---|---|
| Return rows that match one or two simple conditions | FILTER | FILTER is shorter and easier to read when you want the same columns in the same order. |
| Select only some columns or reorder columns | QUERY | QUERY can use SELECT A, B, D and return a report-shaped output directly. |
| Filter by a Google Sheets date range | QUERY or FILTER | FILTER is simpler with date cells; QUERY is better when the result also needs selected columns or sorting. |
| Need ORDER BY or SQL-like report logic | QUERY | QUERY supports clauses such as SELECT, WHERE, ORDER BY, and headers in one formula. |
Sample data
| Date | Region | Product | Amount |
|---|---|---|---|
| 2026-01-04 | East | Widget | 420 |
| 2026-01-12 | West | Widget | 310 |
| 2026-02-03 | East | Gadget | 275 |
| 2026-02-15 | East | Widget | 640 |
Copyable formulas
=QUERY(A1:D100, "SELECT A, B, D WHERE B = 'East' ORDER BY A", 1) Use QUERY when you want selected columns and sorted report output.
=IFERROR(FILTER(A2:D100, B2:B100="East"), "No matches") Use FILTER when you want the original rows and columns that match the condition.
=QUERY(A1:D100, "SELECT A, B, D WHERE A >= date '"&TEXT(F1,"yyyy-mm-dd")&"' AND A < date '"&TEXT(G1,"yyyy-mm-dd")&"'", 1) Use TEXT to convert spreadsheet date cells into QUERY date literals.
How the workflow fits together
- FILTER is usually the fastest choice when the output should keep the source columns unchanged.
- QUERY is stronger when you want a report: selected columns, ordered rows, date literals, and a header-row argument.
- Both formulas run inside Google Sheets. Neither requires uploading a spreadsheet to this site.
- After choosing the pattern, use the matching builder to create your own version with your real ranges and criteria.
Common mistakes
- Do not use QUERY date filters with display dates such as 1/1/2026. Use date 'YYYY-MM-DD' or TEXT(date_cell,"yyyy-mm-dd").
- Do not copy the Google Sheets FILTER syntax into Excel without checking the Excel output; Excel combines conditions differently.
- Do not use QUERY when a simple FILTER formula is easier for teammates to audit.
- Do not use FILTER when you need SELECT, ORDER BY, or report-shaped output.
Related formulas
FAQ
Is QUERY better than FILTER in Google Sheets?
QUERY is better for report-shaped output with selected columns, sorting, and date literals. FILTER is better for simpler row filtering.
Do these formulas work in Excel?
FILTER has an Excel dynamic array version. QUERY is a Google Sheets function and does not work in Excel.
Why is this guide not a blog post?
It includes sample data, copyable formulas, and direct links to deterministic builders that generate the same workflow patterns.