The formula reference

A function for the next step.

Find what you need, see its inputs and result, and try it on an example note.

New to this? Start with your first formula.

173 functions

Number

toNumber

Returns a number from a checkbox, or text like "12.5".

toNumber(number | checkbox | text)
Number

round

Rounds a number to whole, or to the given decimal places.

round(number, places?)
Number

floor

Rounds a number down to a whole number.

floor(number, step?)
Number

ceil

Rounds a number up to a whole number.

ceil(number, step?)
Number

abs

Returns a number without its minus sign.

abs(number)
Number

min

Returns the smallest of some numbers, or of a list.

min(number, …) or min(list)
Number

max

Returns the largest of some numbers, or of a list.

max(number, …) or max(list)
Number

sum

Adds up some numbers, or a list, skipping empty ones.

sum(list) or sum(number, …)
Number

average

Returns the average of some numbers, or of a list.

average(list) or average(number, …)
Number

roundUp

Rounds a number away from zero, to whole or to places.

roundUp(number, places?)
Number

roundDown

Rounds a number toward zero, to whole or to places.

roundDown(number, places?)
Number

roundTo

Rounds a number to the nearest multiple of a step.

roundTo(number, step)
Number

trunc

Drops the fraction of a number, keeping its sign.

trunc(number)
Number

sign

Returns 1, -1 or 0 for a positive, negative or zero number.

sign(number)
Number

mod

Returns the remainder, with the sign of the divisor.

mod(number, divisor)
Number

pow

Raises a number to a power, the same as ^.

pow(base, exponent)
Number

sqrt

Returns the square root of a number.

sqrt(number)
Number

cbrt

Returns the cube root of a number.

cbrt(number)
Number

exp

Returns e raised to a number.

exp(number)
Number

ln

Returns the natural logarithm of a number.

ln(number)
Number

log

Returns the logarithm of a number, base 10 or a base you give.

log(number, base?)
Number

log10

Returns the base-10 logarithm of a number.

log10(number)
Number

log2

Returns the base-2 logarithm of a number.

log2(number)
Number

pi

Returns π, 3.14159….

pi()
Number

e

Returns e, 2.71828….

e()
Number

clamp

Keeps a number between a low and a high.

clamp(number, low, high)
Number

gcd

Returns the greatest common divisor of whole numbers.

gcd(list) or gcd(number, …)
Number

lcm

Returns the least common multiple of whole numbers.

lcm(list) or lcm(number, …)
Number

factorial

Returns the product of the whole numbers up to a number.

factorial(number)
Number

isEven

Returns true when a whole number is even.

isEven(number)
Number

isOdd

Returns true when a whole number is odd.

isOdd(number)
Number

product

Multiplies a list of numbers, or several.

product(list) or product(number, …)
Number

median

Returns the middle number of a list, or of several.

median(list) or median(number, …)
Number

mode

Returns the number a list holds most often.

mode(list) or mode(number, …)
Number

count

Counts a list's items that are not empty, or that pass a test.

count(list, item => condition?)
Number

variance

Returns the variance of a sample of numbers.

variance(list) or variance(number, …)
Number

stdev

Returns the standard deviation of a sample of numbers.

stdev(list) or stdev(number, …)
Number

variancePopulation

Returns the variance of a whole population of numbers.

variancePopulation(list) or variancePopulation(number, …)
Number

stdevPopulation

Returns the standard deviation of a whole population.

stdevPopulation(list) or stdevPopulation(number, …)
Number

percentile

Returns the value below which a fraction of a list falls.

percentile(list, fraction)
Number

rank

Returns a number's place in a list, the largest first.

rank(number, list)
Number

weightedAverage

Averages a list of values, each by its weight.

weightedAverage(values, weights)
Number

formatNumber

Returns a number as text in a style, for joining to other text.

formatNumber(number, style, places?)
Number

sin

Returns the sine of an angle in radians.

sin(radians)
Number

cos

Returns the cosine of an angle in radians.

cos(radians)
Number

tan

Returns the tangent of an angle in radians.

tan(radians)
Number

asin

Returns the angle in radians whose sine is a number.

asin(number)
Number

acos

Returns the angle in radians whose cosine is a number.

acos(number)
Number

atan

Returns the angle in radians whose tangent is a number.

atan(number)
Number

atan2

Returns the angle in radians of the point x, y.

atan2(y, x)
Number

degrees

Turns an angle in radians into degrees.

degrees(radians)
Number

radians

Turns an angle in degrees into radians.

radians(degrees)
General

coalesce

Returns the first value that is not empty.

coalesce(value, fallback, …)
Logic

if

Returns one value when a condition is true, else another.

if(condition, then, else)
Logic

ifs

Returns the value of the first test that is true.

ifs(test, value, otherwise?, …)
Logic

switch

Returns the result whose case equals a value.

switch(value, case, result, otherwise?, …)
Logic

and

Returns true when every value is true.

and(value, …)
Logic

or

Returns true when any value is true.

or(value, …)
Logic

not

Returns the opposite of a condition; empty counts as false.

not(value)
Logic

isEmpty

Returns true for empty values, empty text and empty lists.

isEmpty(value)
General

format

Returns any value as text; a row as its title.

format(value)
Logic

xor

Returns true when exactly one of its values is true.

xor(value, value, …)
Logic

between

Returns true when a value is from a low to a high, both included.

between(value, low, high)
General

typeOf

Returns the kind of a value as text.

typeOf(value)
General

parseNumber

Reads a number written the way a language writes them.

parseNumber(text, locale?)
General

toCheckbox

Reads a checkbox from a number or a word.

toCheckbox(value)
Lists

compact

Removes empty items from a list, keeping zero and false.

compact(list)
Lists

map

Returns a list with one result for each item.

map(list, item => …)
Lists

filter

Keeps only the items for which a condition is true.

filter(list, item => condition)
Lists

find

Returns the first item for which a condition is true.

find(list, item => condition)
Lists

some

Returns true when a condition is true for any item.

some(list, item => condition)
Lists

every

Returns true when a condition is true for every item.

every(list, item => condition)
Lists

reduce

Folds a list into one value, from a start you give.

reduce(list, (total, item) => …, start)
Lists

unique

Removes repeated items from a list.

unique(list)
Lists

sort

Sorts a list, with empty items last.

sort(list, order?) or sort(list, item => key, order?)
Lists

first

Returns the first item of a list.

first(list)
Lists

last

Returns the last item of a list.

last(list)
Lists

includes

Returns true when a list holds a value.

includes(list, value)
Lists

findLast

Returns the last item of a list that passes a test, or empty.

findLast(list, item => condition)
Lists

findIndex

Returns the position of the first item that passes a test.

findIndex(list, item => condition)
Lists

flatMap

Maps each item to a list and joins the lists into one.

flatMap(list, item => list)
Lists

flat

Joins a list of lists into one list, one level down.

flat(list)
Lists

concat

Joins lists end to end.

concat(list, other, …)
Lists

at

Returns the item at a position in a list, counted from 0.

at(list, position)
Lists

uniqueBy

Drops items whose key repeats an earlier item's.

uniqueBy(list, item => key)
Lists

includesAny

Returns true when a list holds any of several values.

includesAny(list, values)
Lists

includesAll

Returns true when a list holds every one of several values.

includesAll(list, values)
Lists

intersect

Returns the items two lists share, in the first list's order.

intersect(list, other)
Lists

union

Returns the items of two lists, each once.

union(list, other)
Lists

difference

Returns the items of a list that another lacks.

difference(list, other)
Lists

minBy

Returns the item with the least key.

minBy(list, item => key)
Lists

maxBy

Returns the item with the greatest key.

maxBy(list, item => key)
Lists

sequence

Returns a list of numbers: a count, from a start, by a step.

sequence(count, start?, step?)
Text

person

Names a person on this shelf.

person(name)
Text

name

Returns a person's name.

name(person)
Text

link

Makes a link to an address, or to a note.

link(label, address) or link(row, label?)
Text

length

Counts the characters in text, or the items in a list.

length(text) or length(list)
Text

lower

Returns text in lower case.

lower(text)
Text

upper

Returns text in upper case.

upper(text)
Text

titleCase

Capitalises the first letter of every word.

titleCase(text)
Text

capitalize

Capitalises the first letter of a text, leaving the rest.

capitalize(text)
Text

trim

Removes spaces from both ends of text.

trim(text)
Text

trimStart

Removes white space from the start of a text.

trimStart(text)
Text

trimEnd

Removes white space from the end of a text.

trimEnd(text)
Text

collapseSpaces

Trims a text and makes each run of white space one space.

collapseSpaces(text)
Text

contains

Returns true when one text contains another; case matters.

contains(text, part)
Text

startsWith

Returns true when text starts with another text.

startsWith(text, start)
Text

endsWith

Returns true when a text ends with another; case matters.

endsWith(text, end)
Text

containsAny

Returns true when a text contains any of a list of parts.

containsAny(text, parts)
Text

containsAll

Returns true when a text contains every part of a list.

containsAll(text, parts)
Text

slice

Takes part of a text or a list, by position from 0.

slice(text, start, end?) or slice(list, start, end?)
Text

textBefore

Returns the text before a part, or empty when it is absent.

textBefore(text, part, n?)
Text

textAfter

Returns the text after a part, or empty when it is absent.

textAfter(text, part, n?)
Text

truncate

Shortens a text to a length, ending it with an ellipsis.

truncate(text, length, end?)
Text

indexOf

Returns where a part first appears in a text, or a value in a list.

indexOf(text, part) or indexOf(list, value)
Text

lastIndexOf

Returns where a part last appears in a text, or empty.

lastIndexOf(text, part)
Text

replace

Replaces every match of one text with another.

replace(text, find, with)
Text

replaceFirst

Replaces the first match of one text with another.

replaceFirst(text, find, with)
Text

split

Splits text into a list at each separator.

split(text, separator, limit?)
Text

lines

Splits a text into a list of its lines.

lines(text)
Text

join

Joins a list's items into one text, with a separator.

join(list, separator?)
Text

repeat

Repeats a text a number of times.

repeat(text, times)
Text

padStart

Pads a text at the start until it is a length.

padStart(text, length, filler?)
Text

padEnd

Pads a text at the end until it is a length.

padEnd(text, length, filler?)
Text

reverse

Reverses a text, character by character, or a list.

reverse(text) or reverse(list)
Text

charCode

Returns the code of the first character of a text.

charCode(text)
Text

fromCharCode

Returns the character for a code.

fromCharCode(code)
Text

encodeUrl

Makes text safe inside a web address.

encodeUrl(text)
Text

decodeUrl

Turns %20 and its kin back into the characters they stand for.

decodeUrl(text)
Text

regexTest

Returns true when a pattern matches somewhere in a text.

regexTest(text, pattern, flags?)
Text

regexExtract

Returns the first match of a pattern, or one of its groups.

regexExtract(text, pattern, group?, flags?)
Text

regexMatch

Returns every match of a pattern, as a list of text.

regexMatch(text, pattern, flags?)
Text

regexReplace

Replaces every match of a pattern.

regexReplace(text, pattern, with, flags?)
Text

regexSplit

Splits a text at each match of a pattern.

regexSplit(text, pattern, flags?)
Text

regexEscape

Returns a text as a pattern that matches it exactly.

regexEscape(text)
Date

today

Returns today's date, without a time.

today()
Date

now

Returns the current date and time.

now()
Date

date

Turns text like 2026-03-15 or 2026-03-15T09:30 into a date.

date(text) or date(year, month, day, hour?, minute?)
Date

dateAdd

Moves a date by an amount of a unit.

dateAdd(date, amount, unit)
Date

dateSubtract

Moves a date back by an amount of a unit.

dateSubtract(date, amount, unit)
Date

dateBetween

Counts whole units from one date to another.

dateBetween(date, from, unit)
Date

startOf

Returns the start of a date's day, week, month, quarter or year.

startOf(date, unit)
Date

endOf

Returns the last day of a date's week, month, quarter or year.

endOf(date, unit)
Date

isSame

Returns true when two dates fall in the same unit.

isSame(date, other, unit)
Date

isWeekend

Returns true for a Saturday or a Sunday.

isWeekend(date)
Date

workday

Moves a date by working days, skipping weekends and holidays.

workday(date, workdays, holidays?)
Date

workdaysBetween

Counts the working days from one date to another, both included.

workdaysBetween(start, end, holidays?)
Date

year

Returns the year of a date.

year(date)
Date

quarter

Returns the quarter of the year a date is in, 1 to 4.

quarter(date)
Date

month

Returns the month of a date, 1 to 12.

month(date)
Date

day

Returns the day of the month of a date, 1 to 31.

day(date)
Date

hour

Returns the hour of a date's time, 0 to 23.

hour(date)
Date

minute

Returns the minute of a date's time, 0 to 59.

minute(date)
Date

second

Returns the second of an instant, 0 to 59.

second(date)
Date

weekday

Returns the day of the week, 1 (Monday) to 7 (Sunday).

weekday(date)
Date

week

Returns the ISO week of the year, 1 to 53.

week(date)
Date

dayOfYear

Returns the day of the year, 1 to 366.

dayOfYear(date)
Date

daysInMonth

Returns how many days a date's month has.

daysInMonth(date)
Date

formatDate

Returns a date as text, in a style such as "long".

formatDate(date, style or pattern?, zone?)
Date

relative

Returns how long ago or how soon a date is, in words.

relative(date)
Date

dateStart

Returns the start of a date, without its end.

dateStart(date)
Date

dateEnd

Returns the end of a date span, or the date itself.

dateEnd(date)
Date

dateRange

Makes a span from a start date to an end date.

dateRange(start, end)
Date

duration

Makes a length of elapsed time from hours, minutes or seconds.

duration(amount, unit)
Date

inDays

Returns a duration as a number of 24-hour days.

inDays(duration)
Date

inHours

Returns a duration as a number of hours.

inHours(duration)
Date

inMinutes

Returns a duration as a number of minutes.

inMinutes(duration)
Date

inSeconds

Returns a duration as a number of seconds.

inSeconds(duration)
Date

formatDuration

Returns a duration as text, in words or as a clock.

formatDuration(duration, style?)
Date

zone

Returns a date's time zone as text, empty when it has none.

zone(date)
Date

inZone

Returns the same moment written in another time zone.

inZone(date, zone)
Date

timestamp

Returns a date as milliseconds since 1970.

timestamp(date)
Date

fromTimestamp

Makes a date from milliseconds since 1970.

fromTimestamp(milliseconds)