Calculator Section
Part of the MountDev Ops Websites documentation. Updated November 29, 2026
MountDev Ops Websites documentation | Updated November 29, 2026
A calculator on a website page lets a visitor change a few numbers and see a result worked out on the spot: what a team would cost, how much they would save, a quote range, or anything else you can write as a formula. It is one general section. Any company can add it to any page, it is built the same way for every company, and it never uses custom code.
Add It to a Page
Websites, then Page Builder, then Add Section, under Sell: Calculator. A new block opens its settings at once. Use Block Settings on the block, or Settings on a phone, to change it later.
What You Set
- Heading and Line Under the Heading: your own words, shown above the calculator.
- Inputs (up to 8): what a visitor sets. Each has a key (a short lowercase name such as
team), a label, and a kind.- Slider: a minimum, a maximum, a step, a starting value, and a unit word such as people.
- Number: the same limits, typed in a box.
- Checkbox: on or off when the page opens, with up to 6 feature lines that show while it is on.
- Choice: up to 12 choices, each with a label, a number it gives to the formulas, and up to 6 feature lines that show while it is picked.
- Saved Values (up to 12): your own numbers, such as
Current CRM, 25, per person per month. They are shown on the page as your own figures. They are not Products. - Catalog Prices (up to 8): the live price of one of your Products, chosen from the same list Insert Price uses (active products with a price, not marked Hide Price on Websites). A Product marked Hide Price on Websites is listed and cannot be chosen.
- Results (up to 6): each has a label, a key, a formula, how to show it (money a month, money one time, or a plain number), whether to show it only when it is above 0, whether it is the big total, and an optional sentence.
Formulas
A formula is a short expression in one fixed grammar. It is not code, and nothing else is allowed.
- Numbers, such as
12or0.5. input.KEY: a slider or number gives its value, a checkbox gives 1 when on and 0 when off, a choice gives the number of the picked choice.value.KEY: one of your saved values.price.KEY: the live price of a catalog price. Its KEY is the short name you gave it, or the Product's public id.- The key of an earlier result, such as
today. +,-,*, and parentheses.MAX(a, b)andMIN(a, b). No other function is allowed.
Example: a saving is MAX(0, today - ours), where today is input.team * value.crm_rate and ours is input.team * price.acme_crm. Mark the saving Show only when above 0, so a visitor never sees a negative figure, and give it the sentence Save about {saving} a month.
A sentence is plain text. Write {key} where a result's value goes. Money shows like $492, and the sentence adds the rest of the words.
Saving checks every formula. An unknown key, a formula that does not read, a function other than MAX or MIN, a result that uses a later result, or a Product that is missing is refused with the line and the reason.
What a Visitor Sees
- Their inputs above, their results beside or below them, with the big total last. The results update as the visitor moves a slider, types a number, ticks a box, or picks a choice. The page does not reload.
- A result whose price cannot show (the Product is turned off, has no price, or is marked Hide Price on Websites) shows nothing, and so does any result that uses it. The Publish check lists the price that cannot show.
- Without script the page shows the results for the starting values, so nothing is blank.
- It works with the keyboard (Tab to move, arrow keys on a slider or choice, Space on a box), focus is visible, targets are at least 44 pixels, and the big total is announced politely after a change. Colors come from the website's theme, in light and dark.
- A visitor's choices are worked out in their browser and are never saved, sent, or counted. No quote, lead, or charge is made.
Prices Stay Current
A price on a Product reaches the calculator the same way it reaches a price block: the published website is built again by itself, with no publish.
Assistants and Keys
An AI assistant, an API key, or a person uses the same actions. No script, style, or HTML is needed.
- Add the section (action
sites.pagesection.add, MCP toolwebsites_page_section_add):typeiscalculator, withtitle,text,inputs,values,prices, andresults. The answer returns the place (index), so the section can be changed later. - Change the section (action
sites.pagesection.save, MCP toolwebsites_page_section_save): send any of those fields; what you send replaces that field and the rest stays. - Read it back (
websites_page_section_get) to check or change it later. - An input is
{ key, label, kind }plusmin,max,step,value, andunitfor a slider or number,onandlinesfor a checkbox, orchoices({ label, number, lines }) andvalue(the starting choice counted from 0) for a choice. A saved value is{ key, label, number, unit }. A catalog price is{ product, key }:productis thepublic_idfromproducts_list, andkeyis an optional short name. A result is{ key, label, formula, format, highlight, positive_only, template }, whereformatismoney_month,money_once, ornumber. - An assistant cannot type a catalog price. It picks a Product. It sets a saved value only when the owner gave it that number.
- Example (made-up data, Acme Test Co):
{ "page_id": 12, "type": "calculator", "title": "See What You Would Save", "inputs": [ { "key": "team", "label": "Team Size", "kind": "slider", "min": 1, "max": 100, "step": 1, "value": 12, "unit": "people" } ], "values": [ { "key": "crm_rate", "label": "Current CRM", "number": 25, "unit": "per person per month" } ], "prices": [ { "product": "k7m2q9x4tbn8", "key": "acme_crm" } ], "results": [ { "key": "today", "label": "You pay today", "formula": "input.team * value.crm_rate", "format": "money_month" }, { "key": "ours", "label": "With Acme Test Co", "formula": "input.team * price.acme_crm", "format": "money_month" }, { "key": "saving", "label": "Saving", "formula": "MAX(0, today - ours)", "format": "money_month", "positive_only": true, "highlight": true, "template": "Save about {saving} a month" } ] }. - A change saved this way stays a draft until a person publishes.
Limits
8 inputs, 12 saved values, 8 catalog prices, 6 results, 12 choices on an input, 6 feature lines each, and 300 characters in a formula.
Where to Find It
Websites, then Page Builder, then Add Section, in the group named Sell. Anyone who may edit websites sees it.
