Skip to main content
Version: Divi 5

Calculation Field

Purpose

The Calculation field type renders a read-only (or optionally editable) value based on a formula that can reference other form fields. You can show the result in the field, when zero, and optionally calculate on the server. Conditional logic can control when the calculation runs.

When to use

  • Totals, discounts, tax, or any value derived from other fields (e.g. quantity × price).
  • When you need server-side calculation or conditional calculation rules.

Key settings

  • Field — Field Type: calculation, Field Title.
  • Calculation — Calculation Formula, Calculation Decimal, Calculate On Server, Show Result In Field, Show Result When Zero, Result Content, Send Ajax Based All Fields, Calculate Logic (conditional rules).
  • Layout — Label, description; Design for result styling.

Top features to configure

  • Calculation formula — Build totals from other field values (for example quantity × price).
  • Calculate on server — Use this for trusted totals used in billing or automation.
  • Show result in field — Display live totals directly to the user while completing the form.
  • Show result when zero — Decide whether to display 0 or keep the output hidden initially.
  • Calculate logic — Apply conditions so formulas run only when relevant.

Validation behavior

  • Calculation values depend on correctly referenced source fields and valid formula syntax.
  • Conditional calculation rules can skip updates when conditions are not met.
  • Server-side calculation is useful when you need trusted results for downstream processing.

Common mistakes

  • Referencing the wrong source field in formulas.
  • Mixing display formatting with numeric logic in ways that break totals.
  • Expecting hidden or conditionally disabled fields to always supply calculation inputs.

Verify it works

  1. Submit test values with known expected totals.
  2. Change inputs and confirm calculation updates correctly.
  3. Validate conditional rules by testing both matching and non-matching conditions.
  4. Confirm saved values in Entries and notifications match front-end totals.

What's Next

  • Review Calculable fields for full formula workflows.
  • Use Number field as a reliable input source for calculations.
  • Check FAQ if totals are not updating correctly.