> ## Content Index
> Fetch the complete content index at: https://airtables.net/llms.txt
> Use this file to discover other available public pages before exploring further.

# Airtable formula builder
- URL: https://airtables.net/airtable-formula-builder/
- Published: 2026-11-10T15:37:04.000Z
- Updated: 2026-11-23T19:51:55.000Z
- Description: Choose a task, enter your field names and copy the formula. Four recipes for text, conditions and dates, with clear return types and blank-date handling.
- Author: Emma Hayes
- Tags: Formulas

Choose a recipe, enter the field names from your Airtable table, and copy the formula. The builder joins two text fields, returns an IF result, shifts a date, or measures the interval between two dates. Each recipe shows its output type. I'd check your field types before pasting, because a date stored as text may need parsing.

## What should the formula do?

Task Join two text fields Return a label or number from a condition Add or subtract time from a date Calculate the difference between dates 

Use the exact field names from your table, without curly braces.

First field 

Second field 

Text between the values 

Starts with one space. Replace it with a comma, dash or your own text.

When a text field is empty Skip when either field is emptyAlways include the separator

Return typeText labelsNumbers Value to match Result when it matches Result otherwise 

Compare one text or single-select value. Choose Numbers for arithmetic; choose Text labels for words or codes.

Amount to add 

Use a whole number. Enter a negative amount to subtract.

Unit days 

Reset fields 

### Your formula

Copy this expression into Airtable CONCATENATE({First name}, IF(AND({First name}, {Last name}), " ", ""), {Last name}) 

Returns **Text**

Adds the separator only when both text fields have values. Existing spaces inside either value stay as entered.

Copy formula [Read the full recipe](https://airtables.net/airtable-concatenate-text/) 

The builder works without signing in or connecting your base. It builds the expression in this page; Airtable calculates it against your records after you paste it. Use the exact field names without curly braces in the inputs. Quotation marks and backslashes in your labels are escaped automatically; the builder accepts single-line field names without braces.

## Choose the recipe from your input fields

__What each builder task expects and returns__
| Your task                             | Input fields                                                  | Result                                                                      |
| ------------------------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------- |
| Join names or labels                  | Two text fields and a separator                               | Text; optional separator only when both values exist                        |
| Return a result when a status matches | One text or single-select field, one match value, two results | Text labels or numbers, selected explicitly                                 |
| Add or subtract calendar time         | One date field and a whole-number offset                      | Date, or blank for a missing date                                           |
| Calculate elapsed time                | End date and Start date                                       | Whole days/hours/minutes, decimal hours, or seconds for Duration formatting |

A formula reads fields in the same record; it doesn't use spreadsheet addresses such as A2 or reach into an arbitrary record. If a customer's renewal date belongs in Customers but your calculation belongs in Orders, bring the value through a [linked-record relationship](https://airtables.net/link-records-in-airtable/) and a suitable lookup or rollup first. Airtable's [formula-field guidance](https://support.airtable.com/articles/8772429326-getting-started-with-the-airtable-formula-field?ref=airtables.net) explains these boundaries. A lookup containing several values isn't the same input as one date.

## Paste the expression into a separate Formula field

Formula fields are available on all Airtable plans. **Owner or Creator** permissions are required to configure them, according to the [field-configuration permissions](https://support.airtable.com/articles/8772429326-getting-started-with-the-airtable-formula-field?ref=airtables.net). Building an expression here doesn't require an Airtable connection.

1. Open the base and the table containing your input fields.
2. Add a new field, give it a clear name and select **Formula** as the field type.
3. Click **Copy formula** here and paste the expression into Airtable's formula editor. If copying is unavailable in your browser, select the expression and use your keyboard's copy command.
4. Inspect the preview against the sample records you intend to calculate. Confirm the input field names and types.
5. Open **Formatting** and choose a format compatible with the result: Decimal for decimal hours, a date format for DATEADD, or Duration for a difference returned in seconds.
6. Click **Create field**. The expression applies to each record in that table, using that record's inputs.

I'd keep the old field while checking the replacement, because a view filter, interface or automation may already read it. If you later replace an existing expression, first save its formula and download the relevant records as a backup. Adding a new calculated field doesn't require converting the source fields or overwriting their values.

## Join text without a stray separator

The default join adds a space only when both text fields contain values. It returns **text**:

```
CONCATENATE({First name}, IF(AND({First name}, {Last name}), " ", ""), {Last name})
```

__Expected results with a space as the separator__
| First name | Last name | Result     |
| ---------- | --------- | ---------- |
| Ada        | Rivera    | Ada Rivera |
| Empty      | Rivera    | Rivera     |
| Ada        | Empty     | Ada        |

Both fields empty produce empty text. This option controls the separator; it doesn't remove existing spaces from either source value. A field containing only spaces still needs cleaning. Use `TRIM()` when trimming is part of your rule; Airtable's [text-function reference](https://support.airtable.com/articles/7330071120-airtable-formula-field-functions-reference?ref=airtables.net) defines TRIM and CONCATENATE.

Select **Always include the separator** when you need a fixed pattern, such as a code with a dash even when one component is missing. For numeric source fields or more than two inputs, use the [CONCATENATE guide](https://airtables.net/airtable-concatenate-text/) to choose the right missing-value condition rather than assuming a numeric zero means “missing.”

[![Formula Builder joins First name and Last name while skipping empty-field separators](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-join.webp)](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-join.webp?ref=airtables.net)

Type the field names exactly as they appear in your table. The builder adds the separator when both values are present. [View full size](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-join.webp?ref=airtables.net).

## Return text labels or actual numbers with IF

For a text or single-select Status field, this recipe returns **text**. An empty Status takes the otherwise branch when the match value is Ready:

```
IF({Status} = "Ready", "Send", "Hold")
```

Choose **Numbers** in the builder to use numeric branches. For example, the following returns a **number** that can be used in later arithmetic:

```
IF({Status} = "Ready", 1, 0)
```

__Two return types for the same status rule__
| Status      | Text recipe | Number recipe |
| ----------- | ----------- | ------------- |
| Ready       | Send        | 1             |
| Empty       | Hold        | 0             |
| In progress | Hold        | 0             |

Entering `0` in Text labels produces `"0"`, a text value. In Numbers it produces `0`. Airtable's [numeric-output formatting](https://support.airtable.com/articles/8772429326-getting-started-with-the-airtable-formula-field?ref=airtables.net) depends on that distinction. The builder keeps the comparison value as text in both modes: it compares Status with Ready, then returns your chosen result.

A formula can format text results as single-select-style options, as described in Airtable's [formula-output formatting](https://support.airtable.com/articles/1638647282-the-essentials-of-airtable-formulas?ref=airtables.net). The result remains computed from the formula; change the input when the status should change. This recipe doesn't test membership in a multiple-select list. For numeric thresholds, several conditions or a separate missing-status branch, use the [IF formula guide](https://airtables.net/airtable-if-formula/).

[![Formula Builder returns Send for Ready, and Hold otherwise](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-if.webp)](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-if.webp?ref=airtables.net)

This example returns text labels. Set Return type to Numbers when a later calculation needs numeric values. [View full size](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-if.webp?ref=airtables.net).

## Add calendar time while leaving missing dates blank

Choose a date field and a whole-number offset. This example adds seven calendar days and returns a **date or blank**:

```
IF({Start date}, DATEADD({Start date}, 7, "days"), BLANK())
```

__Expected results for a seven-day offset, shown as date-only values__
| Start date  | Result      | What it checks       |
| ----------- | ----------- | -------------------- |
| 16 Nov 2026 | 23 Nov 2026 | Ordinary date        |
| Empty       | Blank       | No invented due date |
| 20 Nov 2026 | 27 Nov 2026 | The weekend counts   |

Use `-7` to subtract seven days, or `0` to return the same date. Weeks, months and years are also available. The guard checks the date field, so a zero offset remains valid. Keep the source as a real date field; a text value that looks like a date may need parsing first.

Calendar days aren't working days. Airtable's [date-function guidance](https://support.airtable.com/articles/5452033436-working-with-date-functions-in-airtable?ref=airtables.net) uses WORKDAY to exclude weekends and an optional holiday list. Choose the [WORKDAY recipe](https://airtables.net/airtable-workday/) when the deadline depends on business days, or the [DATEADD guide](https://airtables.net/airtable-dateadd/) for month boundaries and field-based offsets. When time is included, check the source and result time-zone settings together.

[![Formula Builder adds 14 days to Start date with a blank guard](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-add.webp)](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-add.webp?ref=airtables.net)

The output returns a Date when Start date is filled and leaves it blank otherwise. [View full size](https://storage.ghost.io/c/a9/2c/a92c670f-47cf-4c4a-afab-8582761151cb/content/images/2026/11/airtables-formula-builder-add.webp?ref=airtables.net).

## Calculate a date difference in the units you need

The builder subtracts **Start date from End date**. Whole-unit options return a **number or blank**; both dates must be present:

```
IF(AND({End date}, {Start date}), DATETIME_DIFF({End date}, {Start date}, "days"), BLANK())
```

__Expected whole-day results; both dates use 09:00 GMT__
| Start date  | End date    | Days  |
| ----------- | ----------- | ----- |
| 10 Nov 2026 | 12 Nov 2026 | 2     |
| 10 Nov 2026 | Empty       | Blank |
| 12 Nov 2026 | 10 Nov 2026 | −2    |

Whole hours omit the fractional part. For a 09:00 to 10:30 interval on the same day in GMT, whole hours give 1; **hours (decimal)** uses minutes divided by 60 and gives 1.5\. That calculation has minute-level precision. For seconds-level precision in decimal hours, adapt it to seconds divided by 3,600.

```
IF(AND({End date}, {Start date}), DATETIME_DIFF({End date}, {Start date}, "minutes") / 60, BLANK())
```

For an **h:mm** duration, choose **duration (seconds)** and then Duration formatting in Airtable. The same 90-minute interval returns 5,400 seconds, displayed as 1:30\. Airtable's [date-difference examples](https://support.airtable.com/articles/8381355254-calculating-the-difference-between-dates-in-airtable?ref=airtables.net) distinguish decimal hours from the seconds that Duration formatting expects. Don't format a result of 1.5 hours as Duration: Airtable would interpret the underlying number as seconds.

When the gap looks wrong, compare actual times and the **Use the same time zone (GMT) for all collaborators** setting before changing the formula. A displayed date label can hide the time that the calculation reads. The [DATETIME\_DIFF guide](https://airtables.net/airtable-datetime-diff/) covers partial units, reversed dates and elapsed-time decisions.

## Fix the input or type before rewriting the formula

__Symptoms to check after pasting__
| What happens                                    | Check next                                                                                                                                                       |
| ----------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Airtable doesn't recognize a field              | Confirm the field exists in this table. Use its exact name, including internal spaces; don't paste the builder's surrounding braces into a field-name input.     |
| A pasted expression is rejected                 | Copy the complete expression again. Use straight quotation marks, balanced parentheses and commas between arguments. Paste a formula, not a Markdown code fence. |
| A numeric result can't be formatted as currency | Check whether IF returns quoted text. Choose Numbers and keep both branches numeric.                                                                             |
| A date is blank                                 | Check whether a required date is missing. The builder deliberately keeps missing dates blank rather than treating them as a real start or finish.                |
| A lookup gives several values                   | Resolve whether the calculation needs one linked record or an aggregate. Don't force a list of dates into a single-date recipe.                                  |
| The expression runs but the result is wrong     | Check field types, units, date order, time zones and the rule for empty inputs. Syntax alone doesn't establish the intended business rule.                       |

When adapting a recipe, don't use `IF({Amount}, ...)` as a general missing-number check: a numeric zero is false in a truth test. The [logical-function reference](https://support.airtable.com/articles/7330071120-airtable-formula-field-functions-reference?ref=airtables.net) distinguishes truth tests, comparisons and BLANK. Keep the zero case in your sample records. For a specific error message, follow the [formula troubleshooting guide](https://airtables.net/airtable-formula-errors/).

## Need a formula outside these four tasks?

For custom logic, Airtable has a native **Generate formula** option in the formula editor when AI is enabled in the workspace. Its [current formula-generation workflow](https://support.airtable.com/articles/8772429326-getting-started-with-the-airtable-formula-field?ref=airtables.net) also supports describing changes to the generated expression; Omni is another documented route.

Give it the input fields, the required output type and what should happen when an input is missing. For example: “Use the single-select Status field. Return the number 1 when Status is Ready and 0 otherwise, including when Status is empty.” Then inspect the returned expression and preview. A fluent explanation isn't proof that a condition matches your records.

A `filterByFormula` expression for an API request has a different job: deciding which records a request returns. It doesn't add a Formula field to your table. Keep this page's result in a Formula field when you need a reusable value that views, interfaces or other formulas can read; use the [formula basics guide](https://airtables.net/airtable-formula-basics/) for the language around more complex expressions.

## Check the result where the next colleague will use it

Inspect an ordinary record, a record with a missing input and an edge case: a name without a surname, a zero result, a reversed interval or a weekend deadline. The tables above give expected outputs for those specific inputs. If the expression belongs to an existing workflow, open the view or interface that reads the new field and check its filter or formatting. Add a field description stating the inputs, units and missing-value rule so the next maintainer can tell what the result means.