Skip to main content
Version: v7 / v8

Comparison with other libraries

The query builder library most often compared to React Query Builder (RQB) is react-awesome-query-builder (RAQB). Both render an interactive UI for building filter criteria, and both can export those criteria to several query languages, but they take meaningfully different approaches.

This page summarizes the differences as of RQB v8 and RAQB v6.6.15 (May 2025). If you're moving an existing RAQB implementation to RQB, see Migrating from react-awesome-query-builder.

Philosophy

React Query Builderreact-awesome-query-builder
Query storagePlain JSON (RuleGroupType), serializable as-isimmutable.js tree; plain JSON via Utils.getTree()
ConfigurationDiscrete props (fields, operators, combinators, controlElements, etc.)One monolithic Config object (types, widgets, operators, funcs, settings)
PackagingComposable packages — core, React, UI styles, and optional feature packagesCore package plus UI-specific packages
Non-React usage@react-querybuilder/core has no React dependency (server-safe)Core depends on React

RQB's plain-JSON query format means you can store queries in a database, send them over the wire, diff them, and hand-edit them without any conversion step. RQB's discrete props mean you only configure (and only bundle) the parts you use.

Query model

AspectReact Query Builderreact-awesome-query-builder
Group childrenruleschildren1 (array, or keyed object when children1AsArray: false)
Combinatorscombinator on the group, or independent combinators interleaved between rulesconjunction on the group only
Negationnot on groupsnot on groups
Rule valueScalar or array, depending on the operatorAlways an array (one entry per operand)
SubqueriesMatch modesall, some, none, atLeast, atMost, exactly (with threshold)!group fields with some/all/none and count operators
Disabled rulesdisabledisLocked
Muted rulesmuted (kept in the query, excluded from exports)
Ternary/CASEswitch_group / case_group
Value sourcesvalue, field, expressions, parametersvalue, field, func
Left-hand sideExpressions supported on the LHS as well as the RHSfieldSrc: "func"

Formats

RQB's formatQuery supports considerably more export targets, and its parsers support more import sources.

DirectionReact Query Builderreact-awesome-query-builder
ExportJSON, SQL (plain/parameterized/named), MongoDB, CEL, JsonLogic, SpEL, ElasticSearch, JSONata, LDAP, natural language, Drizzle, TanStack DB, Prisma, Sequelize, Cypher, GraphQL, SPARQL, Gremlin, and moreSQL, MongoDB, JsonLogic, SpEL, ElasticSearch (partial), query string
ImportSQL, CEL, JsonLogic, MongoDB, SpEL, JSONata, Cypher, GraphQL, SPARQL, Gremlin, RAQBJsonLogic, SpEL, SQL (separate package)

Ecosystem

AspectReact Query Builderreact-awesome-query-builder
UI style packsAnt Design, Bootstrap, Bulma, Chakra UI, Fluent UI, Mantine, MUI/Material, PrimeReact, TremorAnt Design, MUI, Material (v4), Bootstrap, Fluent UI
React Native@react-querybuilder/native
Drag-and-drop@react-querybuilder/dnd (opt-in)Built in
Date/time@react-querybuilder/datetime (relative dates, per-dialect formatting)Built in (widgets and functions)
Expressions@react-querybuilder/exprBuilt in (config funcs)
Rules engine@react-querybuilder/rules-engine
AccessibilityARIA attributes, keyboard navigation, data-testid hooksNot documented
Internationalizationtranslations prop accepting strings or JSXi18next-based locale packs
ValidationPer-field validator plus defaultValidatorsanitizeTree / validateTree / isValidTree
StylingUnstyled by default with CSS custom properties; official style packsBundled SCSS per UI package

Feature-by-feature notes

Most RAQB concepts have a direct RQB counterpart. These are the exceptions:

  • Ternary (switch_group) — RAQB can build CASE/WHEN-style expressions. RQB has no equivalent in the query builder itself; conditional logic is generally modeled with @react-querybuilder/rules-engine instead.
  • proximity operator — RAQB's full-text proximity operator (and its operatorOptions) has no RQB equivalent.
  • is_empty / is_not_empty — RQB expresses these as = and != against an empty string.
  • Locking — RQB models this with the disabled property rather than a separate locked property, but the behavior and UI are equivalent. The showLockButtons prop displays "Lock rule"/"Lock group" toggle buttons, which set disabled on the rule or group. As in RAQB, a locked group disables its header elements and all descendants. RQB has no equivalent to RAQB's canDeleteLocked setting.
  • Date/time functions — RAQB models NOW, TODAY, RELATIVE_DATETIME, etc. as functions. RQB treats the same concept as a value: @react-querybuilder/datetime relative date/time values, which each rule processor serializes symbolically (e.g. current_timestamp - interval '7 days').
  • Cardinality operators — RQB's match modes are a superset of RAQB's !group count operators, except that RQB has no strict-inequality modes (RAQB's less/greater counts).