How We Count Records
The number of records equals to the total record count across all your indices, including replicas.
Let’s say you have 5,000 records in main index, and three replicas for that index.
This means you would have a total record count of 5,000 x 4 ( primary index + 3 replicas) = 20,000 records.
Your plan may limit the number of records that you can store. As long as you don’t exceed the maximum record count of your plan, you can add, update, or delete as many records as you want.
If you go over this limit, we charge an over-quota based on the maximum number of records you reach. Your plan may let you pre-purchase discounted, additional records at the beginning of your contract period.
To offer flexibility, we ignore the three days when you had the most records. This means we don’t count them in your monthly total record.
How we count operations
We deduct any operations you perform and records that you store from the usage units included in your plan. If your usage exceeds the number of units within your plan, we charge you for the additional units at the end of the billing period.
You can opt to commit to a fixed number of units for the year at a discounted rate. For more details, please visit our pricing page.
Counting indexing operations
We count the following indexing operations:
- Record operations: each addition, update, or deletion on a record counts as one operation. This happens even when nothing changes (for example, if the targeted
- Rule operations: each addition, update, or deletion counts as one operation.
- Synonym operations: each addition, update, or deletion counts as one operation.
- ACL operations: each addition, update, or deletion of an API key or its ACL counts as one operation.
- Index operations: every setSettings call counts as one operation, even if you change several settings at once.
- Moving, deleting, clearing, or copying an index counts as one operation.
Indexing operations limitations
Current Free, Standard, and Premium plans
We don’t count indexing operations or getObjects requests towards your usage for users on our current (starting July 2020) Free, Standard, and Premium plans. However, to prevent extreme numbers of operations impacting your cluster, we implemented a protective limit of 10,000 indexing operations per unit. When exceeding this limit, you get an error message informing you that you reached the indexing limit, so you can reduce the number of indexing operations accordingly.
Legacy plans have monthly operations limitations dependent on the plan. You can see an application’s plan and amount of allotted monthly operations from the Overview section of your Algolia dashboard.
Please keep in mind that some legacy plans count search operations towards the allotted limit, and operations beyond the limit are subject to overage charges.
If you don’t see a limit here, your plan has a customized quota stated in your contract. If you are unsure of your operations limitations, please contact your account team or email@example.com.
Counting reindexing operations
Reindexing lets you update all records in an index, which you can do with the replaceAllObjects method.
For an index with 10,000 records, the reindexing process:
- creates a temporary index,
- indexes 10,000 records,
- and replaces the production index with the temporary one.
In the example above, the reindex counts as 10,001 operations (10,000 for the writes to the temporary index + 1 operation for the move).
Creating an index doesn’t count as an extra operation because it happens as a byproduct of indexing records.
Counting search requests
Every time you make a search request to an Algolia index, or a search request for a multi-index search with multipleQueries, we count one search request. In autocomplete and search-as-you-type implementations, a search happens at every keystroke.
For example, if a user types the word “apple” (five letters) in your search input, it sends a request to Algolia for every character while your user is typing, resulting in five search operations. When searching for “apple” (five letters) in a multi-index search-as-you-type implementation targeting three indices (without using multipleQueries), each keystroke counts as three operations, resulting in 15 search operations total. If you use multipleQueries to perform a search operation, you only make one request to our server, and we only count five search request (one per keystroke).
Legacy plans calculate search operations in the same way, except that a multi-index search with multipleQueries counts a search operation for every query in index. A search with multipleQueries that targets 3 indices, counts as 3 search operations.
Counting InstantSearch operations
Our InstantSearch UI libraries cache all duplicate searches, reducing your search operation count. However, some widgets require two search operations per user input (e.g., the refinementList widget makes one search to get the refinement count, and one to perform the actual search).
Unused usage units and operations, either included in your plan or purchased additionally, don’t roll over to the next service period.
Maximum Queries Per Second (QPS)
Your plan may also have a limit on the maximum allowable QPS (the allowed number of queries performed per second). You can learn more about how we calculate the max QPS, monitor how your max QPS graph evolves over time under the Performance tab of your dashboard, and retrieve the information via the Usage API.
Counting operations on replica indices
Algolia counts operations on replica indices a little differently than with primary indices.
The following replica operations don’t count:
- Propagating data updates from a primary index to a replica index (which happens automatically).
- Propagating settings updates from a primary index to a replica index (via the
However, we count the following operations:
- Updating settings directly on a replica, which counts as one operation.
- Adding a synonym or a Rule directly to a replica, which counts as one operation.
Counting operations in sandbox applications
If your plan has access to a sandbox application, this sandbox has a separate quota. Your sandbox usage doesn’t count towards your regular quota, and the operations on your regular application don’t count towards your sandbox’ quota.