MENU
    Word and character count in Airtable
    • 08 Dec 2023
    • 1 Minute to read
    • Dark
    • PDF

    Word and character count in Airtable

    • Dark
    • PDF

    Article summary

    You can use a formula field to count the number of words, or characters, in another field, and even display a customized message depending on the length.

    Introduction

    Plan availability

    All plan types

    Platform(s)

    Web/Browser, Mac app, and Windows app

    Related reading

    Counting characters in Airtable

    Let's say that you have a base setup to track social media content, and want to make sure your tweets don't exceed the 280 character limit. You can use a formula like the following to output the character count of the text field:

    LEN({Long Text})
    Plain text

    Note that {Long Text} is the name of our field in the table below— you will need to input the name of your text field if you copy this formula.

    Screen Shot 2019-09-04 at 5.54.39 PM

    Displaying messages based on character count in Airtable

    Now, let's say that you're not so interested in the exact character count, but more so that you're under the 280 character limit. Here's an example of an IF statement you can write to check for this and output a message depending on the character count:

    IF(LEN({Long Text})>280, "❌Over Limit", "✅Under Limit")
    Plain text

    Screen Shot 2019-09-04 at 5.58.16 PM

    Using this formula, you'll see either ❌Over Limit or ✅Under Limit for each record depending on the character count in the field your formula is watching.

    Screen Shot 2019-09-04 at 5.59.28 PM

    To reiterate, {Long Text} is the name of our field in the table above— you will need to input the name of your text field if you copy this formula.

    Counting words in Airtable

    For a different workflow, you may be writing editorial content and want to ensure your articles don't exceed a certain word count. You can use a similar formula to count the number of spaces in a text field, which in turn will give you a total count of words.

    IF({Text Field}=BLANK(), 0, LEN({Text Field}) - LEN(SUBSTITUTE({Text Field}, ' ', ''))+1)
    Plain text
    Screen Shot 2019-09-04 at 5.47.31 PM


    Was this article helpful?