# Queries that scale

DevFeed: [Queries that scale](<https://devfeed.tech/articles/queries-that-scale-81428.md>)

Original publisher: [Read original article](<https://stack.convex.dev/queries-that-scale>)

Author: Stack

Published: 2024-02-13T20:00:52Z

Content type: tutorial

Language: en

Sources: [Stack](<https://devfeed.tech/sources/stack.md>)

Topics: [Rockset](<https://devfeed.tech/topics/rockset.md>), [Transactions](<https://devfeed.tech/topics/transactions.md>), [Skiplists](<https://devfeed.tech/topics/skiplists.md>)

Tags: [batching](<https://devfeed.tech/tags/batching.md>), [caching](<https://devfeed.tech/tags/caching.md>), [database](<https://devfeed.tech/tags/database.md>), [patterns](<https://devfeed.tech/tags/patterns.md>), [queries](<https://devfeed.tech/tags/queries.md>), [scaling](<https://devfeed.tech/tags/scaling.md>)

## AI overview

The article explains how to keep Convex database queries efficient as an app grows. It covers indexing to avoid full table scans, limiting or paginating results, and reducing unnecessary cache invalidation by separating frequently updated data and batching online status updates. It also cautions against optimizing before an app has meaningful user growth.

## Source excerpt

As your app grows from tens to hundreds to thousands of users, there are some techniques that will keep your database queries snappy and efficient. I've put together a short list of the most common techniques used by teams scaling on Convex.