YugabyteDB supports the use of PostgreSQL parallel queries. Using parallel queries, the query planner can devise plans that leverage multiple CPUs to answer queries faster.

Currently, YugabyteDB supports parallel queries for colocated tables; support for hash- and range-sharded tables is planned.

To enable and configure parallel queries, set the following configuration parameters.

Parameter Description Default
yb_enable_parallel_append Enables the planner's use of parallel append plans. To enable parallel query, set this to true. false
yb_parallel_range_rows The number of rows to plan per parallel worker. To enable parallel query, set this to a value other than 0. (Recommended: 10000) 0
yb_parallel_range_size Approximate size of parallel range for DocDB relation scans. 1MB

For new universes running v2025.2 or later, parallel append is enabled by default when you deploy using yugabyted, YugabyteDB Anywhere, or YugabyteDB Aeon.

In addition, when upgrading a deployment to v2025.2 or later, if the universe has the cost-based optimizer enabled (on), YugabyteDB will enable parallel append.

In addition, you can use the following PostgreSQL configuration parameters to configure parallel queries:

For more information, refer to How Parallel Query Works in the PostgreSQL documentation.