A calculation field automatically computes a value for every record.
It can be as simple as basic math. For example, in an Orders app, you could create a calculation field called Total cost that multiplies Price by Quantity for each record.
But Tape’s calculation fields can also handle more advanced logic. You can compare values, work with dates, format text, combine information from multiple fields, or create dynamic outputs based on the data in your record.
Calculation fields use variables to reference existing data. Type @ to pick a field from the current record, or step through a relation field to use data from another database app.
The result can be a simple value, like a number, date, or text. It can also return rich content, such as formatted Markdown, custom HTML, or interactive elements like buttons and links. This makes calculation fields useful not only for calculations, but also for creating dynamic labels, summaries, status messages, links, and visual outputs directly inside your record.
Behind the scenes, calculation fields run JavaScript on Node.js. You can start with a simple one-line formula and build more advanced logic whenever you need it.
How to get started
1.) Switch to the new record experience in one of your database apps.
· Click the ••• button in the top right
· Select New Record Beta
· Click Set as default for you (all details ➔)
2.) Open any record in a database app
3.) Unlock the record via the ••• menu in the top right
4.) Click the + icon in the left margin whenever you hover over a new line
5.) Select Calculation from the field type list (Help center ➔)
To configure calculation fields:
Open the ⋮⋮ menu in the left margin when you hover over a calculation field
What stays familiar
A quick look at what you can still do inside a calculation field.
- Display options
- Always show
- Hidden when empty
- Always hide
- Help text is still available. It’s now called “Tooltip”
- JavaScript
Calculations are written in JavaScript. (Introduction) - Built-in libraries
A set of utility libraries for dates, text, IDs, and more, ready to use. (Libraries) - Markdown output
Return Markdown and Tape renders it. (Markdown) - HTML output
Return HTML for richer formatting. (HTML) - Link component
Output clickable links. (Link) - Button component
Output styled buttons. (Button) - Type results: Number, Date, or None - untyped output
What’s new
- Calculations run while creating a record
As you fill in fields on a new record, calculated values update live. Before, they didn’t run until after the first save. - Calculation fields work in forms
Updates live as users fill out the form. Enables many new use cases like live totals and dynamic previews. - End date support
Calculations can now read the end of a date range, not just the start. Long-requested by the community: Date range differences · End date in calculations. - Save without a variable
No@variable required. Useful for static templates, constants, and hard-coded values.Tip: If you’ve referenced a variable like “Last edit” just to make a static calculation save, consider removing it. Every variable change retriggers the calculation, which can flood the organization with traffic. Bulk imports are one example. One more tip: for divider lines, use Tape’s divider block instead. - Trigger automations toggle
Decide per field whether automations trigger when the calculated value changes (turn off while building, back on when ready, to avoid unnecessary traffic in your organization). - Trigger webhooks toggle
Decide per field whether webhooks trigger when the calculated value changes (turn off while building, back on when ready, to avoid unnecessary outbound traffic). - Open the editor in one click
Click an unlocked calculation field to open the editor. Before, it took two or three menu clicks. - Error indicator on broken calculations
A red warning icon next to the field label catches the issue before you open the calculation editor. - Style settings
- Label display and size, placeholder, tooltip, field icon, and more. The full style system is available for the calculation field.
- Top and bottom description
- Add helper text above or below the field: instructions, units, context, or hints for people filling out a form.
- Rearranging calculation fields
- Use the ⋮⋮ handle next to the field label to drag and drop calculation fields. Reorder them, move them around the record, or place them into different columns.
New calculation editor
The new calculation editor is the same one we already use in Tape automations. Many of you have asked for a similar experience in calculation fields.
The new editor lives inside the new record experience. It brings many advantages, plus a few new things worth knowing.
What’s better in summary:
- Write more, click less to work faster
Less menu-clicking, more direct typing. Suggestions and shortcuts shave seconds off every edit. - Built for heavy code and complex records
Records with many fields stay readable. Long calculations stay navigable. The editor scales with what you build. - Better with AI
Calculations are easier to work with in AI tools because the syntax is plain text. You can copy a calculation into an AI chat, make changes, and paste it back without rework. Variables and references stay intact. - Future-ready
The technology is made for the long run. New capabilities will be built here.
Worth knowing for day-to-day
- Autocomplete for variables and properties (
@optional)
Type@for a searchable list of variables (your fields) and properties (Tape built-ins likeRecord_ID). When the editor recognizes a name as you type, suggestions appear on their own. - Navigate relations with dot notation
When you reference a relation field, type.to step into the related app and pick a field. Type.again for aggregations like.allor.allWithNull. Build chains likebelongs_to_company.full_name.allwithout leaving the editor. Spaces in field names display as underscores. - Live preview
See the result of your calculation in the editor. No need to save or leave to check the output. - Preview with: Record
Inside the editor, pick any record from the same app and see what your calculation would output for it. Test edge cases like empty fields, large numbers, or unusual relation chains without saving and jumping back and forth between records. - Open in fullscreen
Click the fullscreen icon or presscmd/ctrl+Enterto expand the editor. - Created and edited info on hover
The editor header shows when the calculation was last touched: “Created X ago” or “Edited X ago”. Hover the timestamp to see who created the calculation, who last edited it, and the dates. - Hover info on field references
Hover any field token to see its full context: field name, value type, the app it lives on, and the Workspace, App, and Field IDs. - Live field references
When you rename a field in your app, every reference in your calculation follows the new name.
Advanced editing features
- Find and replace with regex
Presscmd/ctrl+Fto open the find-and-replace panel.Find:AaMatch Case ·ab,Whole Word ·.*Regex ·↑ ↓Previous/Next ·☰Find in Selection ·XClose.Replace:ABPreserve Case · Replace one · Replace all. - Change all matches at once (
cmd/ctrl+D)
Place your cursor on a word, presscmd/ctrl+Dto add a cursor at the next occurrence. Repeat for every match, then type to rename them all in one go. - Multi-cursor and column selection
HoldAlt/Optionand click to place multiple cursors. HoldShift+Alt/Optionand drag for rectangular selections across lines. - Auto-closing brackets and quotes
Type(,[, or"and the closing character appears with your cursor between. - Line manipulation shortcuts
Move (Alt/Option+↑/↓), duplicate (Shift+Alt/Option+↑/↓), or delete (cmd/ctrl+Shift+K) entire lines without selecting them. - Go to line
cmd/ctrl+G, type a number, hitEnter - Command palette
PressF1for a searchable list of every editor action. - Performance and accessibility
Virtualized rendering keeps very long calculations smooth. Full keyboard navigation and screen-reader support.
How saving works
Calculation editor:
• Auto-save on close Click X or anywhere outside the editor to save your changes.
Calculation editor fullscreen:
• Save button Saves your changes and closes the editor.
• Cancel button Closes the editor without saving.
In both:
• Discard all changes button Reverts the calculation to what it was when you opened the editor.
• Undo and redo cmd/ctrl + Z and cmd/ctrl + Shift + Z work as expected.
Classic editor and new editor
The best part for you. Both editors use the same data model for your calculations. Switching changes how you edit, not what gets stored.
- In the classic record: every calculation field uses the classic editor.
- In the new record experience:
- New calculation fields use the new editor by default.
- Existing ones stay on the classic editor, with a switcher in the top right.
We want every migration to be your choice, so no field switches on its own. The Tape team has moved all of our calculation fields to the new editor because it’s faster and all future improvements will be built there. But you don’t have to do anything. Everything will continue to work as before, and you can migrate when you’re ready.
On top of that, once a field is on the new editor, you can use “Remove classic editor” to drop the switcher. The classic editor is no longer available on that field. We use it ourselves to keep things clean. Made for those who want the same.
Keep building together
Calculation fields are one of the features that brought many of you to Tape. Together with automations, they are some of the most used features in Tape and generate the highest activity.
This update is shaped by years of community feedback. We couldn’t have taken calculation fields to the next level without you. Thanks for being part of the journey. Keep the feedback coming.
➔ Feature Requests
➔ Bugs & Issues
If you want to get a head start, just duplicate the template workspace ➔
More details in the new calculation cheat sheet ➔
Happy building.
