Share
Explore

icon picker
Coda vs. Notion Formulas

What do they share and where do they differ?
Let’s be honest - Notion formulas 2.0 are awesome. They were a big leap in the product and something that brings Notion’s capabilities closer to Coda’s.
There were even some updates that I wish Coda would implement. These include a native index logic for looping and a lets() formula that allows for naming multiple variables at once.
Even with those updates, there are still aspects to Notion's formula experience that I find lacking in comparison to what Coda offers the formula-writing-nerd - Personal opinion, read on to form your own!
Some of those things are minor and would simply make writing formulas more pleasant. Then there are larger differences in the two platform’s approaches to formulas that make the them significantly different in terms of the types of workflows they can support.
Let’s look at the larger differences in formula approaches and then finish up with the small things.

1-circle-c

The Big Ones

The more significant differences between Coda and Notion’s approaches to formulas

Canvas formulas

Notion empowers you to write formulas in columns and table filters, while Coda allows for formula writing in nearly every aspect of its product. In Coda you can write formulas absolutely anywhere! Some places you can write formulas are:
Table filters
Conditional formats
Table Columns
Column options
Inline / Canvas formulas
Automations
Buttons

For example, I can write a formula right here that displays the current date → Today is
Friday
, it is the month of
December
in the year
2024
.
Did you notice that the sentence above is correct? No matter what day you are reading this it is correct because that sentence is a formula. In fact, here is the current time and date, drawn out by a formula:
12/13/2024 5:30:44 PM
.
These are called inline formulas or canvas formulas (as the area where you are reading this is referred to as the canvas in a Coda doc).
Being able to write formulas inline or on the canvas opens up a world of possibilities, including the creation of some truly amazing dashboards that can track your progress, visualize data, and so much more!
image.png
Every number in red you see above shows an inline formula drawing out information from your databases for live, up-to-date information

Action formulas

Action formulas are likely one of the largest ways Coda’s approach differs from Notion, so it’s important to cover this area in a bit more depth.
First, let’s explore the difference between two larger types of formulas: Passive and Active

Passive vs Active Formulas

In Notion, formulas are passive in nature. They take a set of inputs and produce an output, but they do not have the ability to make changes to anything other than their output.
On the other hand, Coda's action formulas are all active, enabling users to take actions that modify data in the doc, trigger actions within the app, or make changes in external services.
Here’s a full list of Coda’s button options (not including actions that involve external services):
image.png

Changing Data in Your Doc

One of the key capabilities of Coda's action formulas is the ability to change data in your doc. Users can add or modify rows, duplicate pages, set control values, and perform various other data manipulation tasks.
This level of interactivity allows for dynamic updates and makes it easier to automate repetitive tasks, perform more advanced calculations, and create more app-like experiences for users.
down
Here’s a quick example. Use the buttons and sliders below to see action formulas in, well, ACTION.
Add rows to your table
00
7
Add 7 rows to your table
Reference the current month, and add all dates
Add all dates from this month
Reset your table and try again!
Reset Table
My Added Rows

Making Changes in External Services

In addition to changing data within the doc and triggering actions in the app, Coda's action formulas can also make changes in external services. This integration capability opens up a world of possibilities, allowing users to create calendar events in Google Calendar, update the status of Jira issues, send messages in Slack, and more.
search

Interested in what packs are available? Search below for some of the
702
available packs!

Search for a pack here:
Blank
By seamlessly connecting with external services, Coda empowers users to automate tasks and streamline their workflows across different platforms.
Coda’s button actions are also configurable by users and able to connect with an service that has an API. So if a connection for a button action doesn’t already exist, you can build it yourself!

Manual and Automatic Execution

Coda's action formulas can be executed manually or automatically.
Users have the flexibility to add these actions to buttons or automations, which can be triggered either by user interaction or automated events included inbound webhooks.

Endless references

Coda allows you to reference anything in your doc from anywhere else in your doc. You can infinitely refer to other databases, other column in other pages, controls and sliders on the canvas and more.
Notion formulas only allow you to reference properties that are immediately accessible in the table in which you are writing a formula.

1-circle-c

The Small Things

Small aspects to writing formulas in Coda that make the experience easier, more accessible and less prone to human error

Output type hints

Numbers, lists, text, row-references, dates, true/false. All of these are data-types and every time you write a formula in Coda or Notion the output of your formula has a certain type. Understanding these types are crucial to writing formulas that work, and using or referencing that data later on.
In Coda, when you are writing any formula you are always given live information on what the final data-type your formula will output.
image.png
While writing formulas you will always see an icon in this area. This specific screenshot shows that the output type of my formula is a number.
See for a full list of Coda data-types and the icons that correspond to them.

Object hint types (by icon or clicking)

When writing formulas in Coda, each object in your formula (which corresponds to a row, column, table, etc) will give you a hint as to what its data type is.
Understanding the data type of an object makes writing formulas 100x easier, and even more importantly, they help you understand what you cannot do in a formula.
For example:
You can’t add/subtract text values, only numbers
You can’t use list operators on values that aren’t lists (slice , splice , count , filter )
You can’t check if a task is coming up this week, if you aren’t comparing date values
You can’t count the number of tasks due for a project, if the tasks aren’t held as a list
Coda makes it extremely easy to see the data types of every referenced object in a formula. For example, this formula below shows:
Icon shows data type of a table
Icon shows data type of a date-value
Icon shows data type of a date-value
Icon shows data type of a boolean (true/false) value
Icon shows data type of text
Icon shows data type of list of numbers

image.png
If you want to see a full list of the 25 different data-types possible within Coda formulas, check this doc out 👇

Reference highlights (eg. referenced column)

Formulas can and do often become complex, referencing different columns or objects within your databases.
When writing a Coda formula, everything you reference is highlighted in your doc itself to help you better understand where your data is coming from and what data you specifically are referencing.
image.png
In this screenshot you can see highlighted in green and pink the different columns and objects referenced in your formula.

Full screen formula editing

The more you begin to rely on tools like Notion and Coda - the more complex your formulas will become. Trust me on this one.
For long formulas - Coda provides a larger, more full screen editing experience so you can see or comment in every part of your formula as you write it.
image.png
Editing formulas in full-screen is optional - but helps immensely for longer or more complex formulas.

Auto formatting

Long formulas can become near impossible to understand without formatting - and a formula that cannot be understood cannot be modified and fixed.
Coda provides auto-formatting of formulas with the click of a button that leads to more easily understandable formulas.
Notion allows for breaking lines and ignoring white-space like Coda formulas, but all formatting must be manually inserted.
Screen Cast 2023-09-16 at 2.20.40 PM.gif
Click auto-format for instantly beautiful formulas.

Single line comments (with //)

Traditional coding in Javascript allows you to comment in two ways
Blocks of comments with /* */
/* Enclosing anything with this syntax allows one to insert blocks of comment ignored when a script is run */
Single line commenting with //
// For smaller bits of comments, Javascript allows you to add single lines of comments
Coda allows for both blocks of comments and single line commenting while Notion only allows for comment block syntax. While a minor note, typing // is significantly easier than type /* .
image.png
Notion formula showing inability to use single-line commenting syntax

Auto suggest comparison values

image.png

In Coda, when you are writing formulas and referencing select-lists or relations to other tables you get auto-suggestions for the possible selection types.
These auto-selections make formula writing quicker and more accurate as the user is less prone to spell something wrong and receive invalid results.

Stable comparisons

Even more importantly, Coda’s comparisons are stable. For example, in the formula to the right, a user is filtering contract types to find contracts that are Current.
If the user later changes the selection type for Current to Active, the formula itself will not break as its tied to the underlying object or selection itself and not to the actual text or wording of a selection.
If the same workflow in the GIF to the right was done in Notion, all formulas connected to that option would be broken.
These stable relations mean a doc is less prone to breaking when workflows or wording in a doc are modified.
Screen Cast 2023-09-16 at 2.34.22 PM.gif

Auto-complete syntax

In traditional coding environments certain characters are autocompleted with its pair to simply make writing code easier.
For example, if you type a ( in code, you very likely will need another matching ) afterwards. Or if you type a " you will likely need another " to close the quotation.
In Coda, these are always auto-completed for you. Notion’s editing experience doesn't auto-complete any of these common syntaxes.
What do you think? Did I miss anything or get anything wrong? Let me know on twitter (@thecodaguy) or through email (scott@simpladocs.com)
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.