Follow these steps only If you see the "Calculating" indicator on your doc. If you are unsure what the cause of performance issues in your doc is, take a look at this article Improving Performance.

Formulas are one of the most powerful aspects of Coda. You can write formulas that let you do very complex calculations. However, some of those calculations can be slow on larger docs. We are actively working on making improvements to performance, but in the meantime this article can help you optimize your docs.

1. A few important things to keep in mind:

  • Coda runs calculations on your device instead of the cloud. Even though Coda is a collaborative tool, the calculations themselves use the resources of your computer to complete. This means that Coda is smoother when you don't have other expensive tasks running in the background. More importantly, this also means that if your doc is calculating something, you will need to leave it open for it to finish calculating.

  • Take a strategic and iterative approach. If you have a big doc that is slow, it's likely to be just a few of the formulas causing the majority of the issues. Rather than trying to optimize every single formula, just focus on using the tool below to find the key issues. When you make a change to one of the slow formulas, test out the improvements. 

  • Most formulas won't run into this. Most Coda users are building formulas that won't run into calculation issues, but for some robust use cases, these issues might crop up. Our recommendation is to start building and troubleshoot as needed.

2. Identify what is calculating in your doc:

We've built a tool that helps you see what is calculating in your doc. It allows you to measure how long a certain interaction takes, and where that time was spent. Using this tool, you can easily identify which formulas are taking a long time to calculate. Keep in mind, this tool only shows issues that are related to calculation. If your doc is slow but it does not have the word "Calculating" showing up on the top for more than a couple of seconds at any given time, take a look at the the sections for Rendering Issues or Memory Issues.

If your doc is already calculating something, wait for it to finish calculating before using the tool. While your doc is still calculating, you might see results in the tool but those may not be the ones you need to worry about. They may be the calculations that already completed quickly and if your doc is still calculating, the problem could be with some other formula that isn't in the results yet.

How to open the Performance Analyzer

If your doc is currently calculating, you can bring up the tool by clicking the Calculating indicator to jump into the tool.

You can also open the tool by opening the Doc Map, then clicking the 3 dots on the top right and then clicking Debug calculations.

If your doc is already calculating something, press the Start Measuring button and wait for it to finish calculating. Sometimes big docs can be slow because someone else is causing new calculations in your doc or because data is being added to it using Zapier or the Coda API. This tool will report on all these calculations rather than just ones that you have initiated. You might want to start by making a copy of your doc to use for diagnosing the issues.

Once your doc finishes calculating, the tool will show you a sorted list of how long each of the formulas took. Follow the suggestions below to fix those formulas before you do anything else. 

If your doc is NOT currently calculating

To figure out what the issue is in those cases, follow these steps:

  1. Make sure the doc is not calculating.

  2. Open the Performance Analyzer and click "Start Measuring".

  3. Perform the action that is slow just once and wait for it to finish. Remember, the results are not accurate while your doc is still calculating.

3. How to fix the calculation issues

When your doc is done calculating, the tool will show you a sorted list of how long each of the tables in your doc took to calculate. You can click the name of the table to jump to it and also expand it to see how long each individual column took.

Once you know what the slow formulas in your doc are, take a look at the Optimizing Slow Formulas article.

Did this answer your question?