Excel Functions

Clear, complete guides to the Excel functions that matter — written by the trainers at Excel Experts. Every guide includes copy-ready formulas, interactive demos you can try right on the page, the errors and pitfalls nobody warns you about, and a free practice workbook.


Lookup & Reference

Functions that find things: a price for a product, a name for an ID, every order in a region.

ADDRESS

All versions

Build a cell address as text from row and column numbers - "$C$5" - with control over $ style, R1C1, and sheet names. Pairs with INDIRECT.

=ADDRESS(5, 3)
Full guide, demos & practice file →

AREAS

All versions

Counts the separate rectangular blocks inside a reference - wrap multi-area unions in an extra pair of parentheses.

=AREAS(reference)
Full guide, demos & practice file →

CHOOSE

All versions

Pick a value from a list by position — index 2 returns the second value. One selector cell can switch entire ranges in and out of a model.

=CHOOSE(index_num, value1, value2, …)
Full guide, demos & practice file →

CHOOSECOLS

365 / 2024+

Return just the columns you want from a table — in any order. Negative numbers count from the end, so -1 is always the last column.

=CHOOSECOLS(array, 2, 4)
Full guide, demos & practice file →

CHOOSEROWS

365 / 2024+

Return just the rows you want from a range by position. Negative numbers count from the bottom — -1 is always the newest row of a growing log.

=CHOOSEROWS(array, -1)
Full guide, demos & practice file →

COLUMN

All versions

Return the column number of a cell - A is 1, B is 2 - or of the formula's own cell. Automates VLOOKUP's col_index_num for drag-across lookups.

=COLUMN() · =COLUMN(D5)
Full guide, demos & practice file →

COLUMNS

All versions

Count how many columns a range or array spans. Builds VLOOKUP column indexes that survive inserted columns.

=COLUMNS(B1:G1)
Full guide, demos & practice file →

DROP

Excel 365

Returns an array with rows or columns removed from its edges - drop headers with 1, totals rows with -1.

=DROP(array, rows, [columns])
Full guide, demos & practice file →

EXPAND

Excel 365

Grows an array to a fixed size, padding new cells with a value you choose - or with #N/A errors if you forget pad_with.

=EXPAND(array, rows, [columns], [pad_with])
Full guide, demos & practice file →

FILTER

365 / 2021+

Return every row that meets your criteria — one formula, many results, updates automatically.

=FILTER(range, criteria, "if empty")
Full guide, demos & practice file →

FORMULATEXT

Excel 2013+

Returns another cell's formula as a text string - perfect for audit columns, documentation, and spotting pasted-over values.

=FORMULATEXT(reference)
Full guide, demos & practice file →

GETPIVOTDATA

All Excel versions

Pulls a value out of a PivotTable by describing it with field/item pairs, so the formula survives pivot rearranging.

GETPIVOTDATA(data_field, pivot_table, [field1, item1], ...)
Full guide, demos & practice file →

GROUPBY

Excel 365

Builds a PivotTable-style grouped summary with one spilling formula that recalculates live.

GROUPBY(row_fields, values, function, [field_headers], [total_depth], [bin_function], [sort_order], [filter_array])
Full guide, demos & practice file →

HLOOKUP

All versions

VLOOKUP's horizontal twin: find a value in the top row of a table and return a value from a row below.

=HLOOKUP(value, table, row_num, FALSE)
Full guide, demos & practice file →

HSTACK

Excel 365

Places ranges or arrays side by side — left to right — into a single spilled result.

HSTACK(array1, [array2], …)
Full guide, demos & practice file →

HYPERLINK

All Excel versions

Creates a clickable link to a web page, email, file, or cell, displaying friendly text of your choosing.

HYPERLINK(link_location, [friendly_name])
Full guide, demos & practice file →

IMAGE

Excel 365

Places a picture inside a cell from an https URL, so it sorts, filters, and moves with its row.

IMAGE(source, [alt_text], [sizing], [height], [width])
Full guide, demos & practice file →

INDEX

All versions

Return the value at a given row and column of a range. Half of the famous INDEX/MATCH combo.

=INDEX(range, row_num, col_num)
Full guide, demos & practice file →

INDIRECT

All Excel versions

Turns a text string like "North!B9" into a live cell reference, so references can be assembled from cell values.

INDIRECT(ref_text, [a1])
Full guide, demos & practice file →

LOOKUP

All versions

Legacy approximate-match lookup across a vector. Still handy for tier tables and last-value tricks.

=LOOKUP(value, lookup_vector, results)
Full guide, demos & practice file →

MATCH

All versions

Find the position of a value in a row or column. The other half of INDEX/MATCH.

=MATCH(value, range, 0)
Full guide, demos & practice file →

OFFSET

All Excel versions

Returns a reference shifted a given number of rows and columns from a starting cell, optionally resized to a height-by-width range.

OFFSET(reference, rows, cols, [height], [width])
Full guide, demos & practice file →

PIVOTBY

Excel 365 only

Builds a live cross-tab - row groups, column groups, aggregated values, and totals - from one spilling formula. GROUPBY's 2-D sibling.

=PIVOTBY(row_fields, col_fields, values, function, ...)
Full guide, demos & practice file →

ROW

All versions

Return the row number of a cell - or of the formula's own cell. Powers numbering that repairs itself when rows are deleted.

=ROW() · =ROW(C7)
Full guide, demos & practice file →

ROWS

All versions

Count how many rows a range or array spans - full or empty. Great for measuring FILTER results and building running counts.

=ROWS(A2:A100)
Full guide, demos & practice file →

RTD

Needs RTD server

Receives live pushed data - market quotes, sensor feeds - from an installed real-time data server. A connector, not a data source: no add-in, no data.

=RTD(prog_id, server, topic1, [topic2], ...)
Full guide, demos & practice file →

SORT

Excel 365

Returns a sorted copy of a range that spills onto the sheet and re-sorts itself whenever the source data changes.

=SORT(array, [sort_index], [sort_order], [by_col])
Full guide, demos & practice file →

SORTBY

Excel 365

Sorts a range by one or more other ranges - the sort keys never have to appear in the spilled result.

=SORTBY(array, by_array1, [sort_order1], ...)
Full guide, demos & practice file →

TAKE

Excel 365

Keeps only the first or last rows and columns of an array - negatives count from the end. The go-to wrapper for top-N lists.

=TAKE(array, rows, [columns])
Full guide, demos & practice file →

TOCOL

Excel 365

Flattens any range or array into a single column, with control over blanks, errors, and reading order.

TOCOL(array, [ignore], [scan_by_column])
Full guide, demos & practice file →

TOROW

Excel 365

Flattens any range or array into a single row, with control over blanks, errors, and reading order.

TOROW(array, [ignore], [scan_by_column])
Full guide, demos & practice file →

TRANSPOSE

All versions

Flip a range on its diagonal — rows become columns and columns become rows — with a live link to the source. Spills in 365, Ctrl+Shift+Enter before.

=TRANSPOSE(array)
Full guide, demos & practice file →

TRIMRANGE

Excel 365 only

Strips blank outer rows and columns from a reference - makes whole-column references fast and safe. Shorthand: the A1:.E10 trim-ref operators.

=TRIMRANGE(range, [trim_rows], [trim_cols])
Full guide, demos & practice file →

UNIQUE

Excel 365

Returns a live, spilled list of distinct values - or, with exactly_once, only the values that appear a single time.

=UNIQUE(array, [by_col], [exactly_once])
Full guide, demos & practice file →

VLOOKUP

All versions

The classic: find a value in the first column of a table and return a value from another column in the same row.

=VLOOKUP(value, table, col_num, FALSE)
Full guide, demos & practice file →

VSTACK

Excel 365

Stacks ranges or arrays vertically — one on top of another — into a single spilled result.

VSTACK(array1, [array2], …)
Full guide, demos & practice file →

WRAPCOLS

Excel 365

Folds a single row or column of values into a grid, filling column by column at the height you choose.

WRAPCOLS(vector, wrap_count, [pad_with])
Full guide, demos & practice file →

WRAPROWS

Excel 365

Folds a single row or column of values into a grid, filling row by row at the width you choose.

WRAPROWS(vector, wrap_count, [pad_with])
Full guide, demos & practice file →

XLOOKUP

365 / 2021+

The modern lookup: searches any direction, exact match by default, built-in error handling. Replaces VLOOKUP and HLOOKUP.

=XLOOKUP(value, lookup_range, return_range)
Full guide, demos & practice file →

XMATCH

365 / 2021+

The modern MATCH: find a value's position with exact match by default, search from the end, and no-sort next-smaller/larger modes.

=XMATCH(value, range)
Full guide, demos & practice file →

Logical

Functions that decide things: tests, branching, error handling, and the LAMBDA family for building your own functions.

AND

All versions

Returns TRUE only when every condition is TRUE - the strict gatekeeper for multi-condition IF tests.

=AND(logical1, [logical2], ...)
Full guide, demos & practice file →

BYCOL

Excel 365

Feeds each whole column of a range to a LAMBDA and spills one result per column - a totals row, monthly maximums, or per-column verdicts from one formula.

=BYCOL(array, LAMBDA(column, body))
Full guide, demos & practice file →

BYROW

Excel 365

Feeds each whole row of a range to a LAMBDA and spills one result per row - row totals, row maximums, and per-row verdicts from a single formula.

=BYROW(array, LAMBDA(row, body))
Full guide, demos & practice file →

FALSE

All versions

Returns the logical value FALSE; kept for compatibility - the plain literal FALSE is equivalent. In math, FALSE coerces to 0.

=FALSE()
Full guide, demos & practice file →

IF

All versions

Tests a condition and returns one value when it's TRUE and another when it's FALSE - the foundation of every spreadsheet decision.

=IF(logical_test, [value_if_true], [value_if_false])
Full guide, demos & practice file →

IFERROR

All versions

Returns a formula's result when it works and your fallback when it raises any error - the universal (and sometimes too eager) safety net.

=IFERROR(value, value_if_error)
Full guide, demos & practice file →

IFNA

Excel 2013+

Replaces only the #N/A error with your fallback and lets every other error through - the safer wrapper for VLOOKUP, XLOOKUP, and MATCH.

=IFNA(value, value_if_na)
Full guide, demos & practice file →

IFS

Excel 2019+

Checks a flat list of conditions in order and returns the value for the first one that's TRUE - nested IF without the nesting.

=IFS(logical_test1, value_if_true1, [logical_test2, value_if_true2], ...)
Full guide, demos & practice file →

LAMBDA

Excel 365

Builds your own reusable custom function from formula logic - test it inline, then save it in Name Manager and call it like a native function.

=LAMBDA([parameter1, ...,] calculation)
Full guide, demos & practice file →

LET

Excel 365

Names values and expressions inside a formula, then reuses them in a final calculation - more readable, and each value computes only once.

=LET(name1, value1, ..., calculation)
Full guide, demos & practice file →

MAKEARRAY

Excel 365

Generates a brand-new array of any size, computing each cell from its row and column indexes - multiplication tables, checkerboards, and calendar grids from one formula.

=MAKEARRAY(rows, cols, LAMBDA(row_index, col_index, body))
Full guide, demos & practice file →

MAP

Excel 365

Applies a LAMBDA to every element of an array and spills the transformed array back - pass several same-size arrays to zip them together.

=MAP(array1, [array2, ...,] lambda)
Full guide, demos & practice file →

NOT

All versions

Reverses a logical value: TRUE becomes FALSE and FALSE becomes TRUE. The cleanest way to express 'everything except' conditions.

=NOT(logical)
Full guide, demos & practice file →

OR

All versions

Returns TRUE when at least one condition is TRUE - the lenient counterpart to AND for any-of-these IF tests.

=OR(logical1, [logical2], ...)
Full guide, demos & practice file →

REDUCE

Excel 365

Folds an array down to a single value by carrying an accumulator through every element - Excel's general-purpose loop.

=REDUCE([initial_value], array, LAMBDA(acc, value, body))
Full guide, demos & practice file →

SCAN

Excel 365

Walks an array with an accumulator and a LAMBDA, returning every intermediate result - running totals and products in one spilled formula.

=SCAN([initial_value], array, lambda(acc, value, calc))
Full guide, demos & practice file →

SWITCH

Excel 2019+

Compares one expression against a list of exact values and returns the matching result, with an optional default for everything else.

=SWITCH(expression, value1, result1, [value2, result2], ..., [default])
Full guide, demos & practice file →

TRUE

All versions

Returns the logical value TRUE; kept for compatibility - the plain literal TRUE is equivalent. In math, TRUE coerces to 1.

=TRUE()
Full guide, demos & practice file →

XOR

Excel 2013+

Exclusive or: TRUE when an odd number of arguments are TRUE. With two tests, that means one or the other - not both.

=XOR(logical1, [logical2], ...)
Full guide, demos & practice file →

Text

Functions that shape words and strings: split, join, extract, clean, convert, and format text exactly how you need it.

ARRAYTOTEXT

Excel 365

Converts a whole range or spilled array into one text string - concise comma list by default, or exact formula-style array syntax with format 1. The strict mode is Excel's best debugging lens.

=ARRAYTOTEXT(array, [format])
Full guide, demos & practice file →

ASC

All versions

Converts full-width (zenkaku) letters, digits, and katakana to half-width (hankaku) - the fix for Japanese imports where '123' is text that will not sum or match.

=ASC(text)
Full guide, demos & practice file →

BAHTTEXT

All versions

Converts a number to Thai text spelled out as baht currency - Excel's only built-in number-to-words function. No English version exists; use LAMBDA or VBA for that.

=BAHTTEXT(number)
Full guide, demos & practice file →

CHAR

All versions

Returns the character for an ANSI code number (1-255). The classic move: CHAR(10) inserts a line break inside a formula.

=CHAR(number)
Full guide, demos & practice file →

CLEAN

All versions

Deletes non-printable control characters (ASCII 0-31) from text - the invisible junk that imports drag in. Pair with TRIM for a full scrub.

=CLEAN(text)
Full guide, demos & practice file →

CODE

All versions

Returns the ANSI code (1-255) of the first character of a text string. The detective tool for unmasking invisible characters that break lookups.

=CODE(text)
Full guide, demos & practice file →

CONCAT

Excel 2019+

Joins text from cells, strings, and whole ranges into one value - the modern replacement for CONCATENATE, minus a delimiter option.

=CONCAT(text1, [text2], ...)
Full guide, demos & practice file →

CONCATENATE

All versions

Joins up to 255 individual text items into one string - the legacy function that works in every Excel version but cannot accept ranges.

=CONCATENATE(text1, [text2], ...)
Full guide, demos & practice file →

DBCS

All versions

Converts half-width (hankaku) characters to full-width (zenkaku) - the opposite of ASC, and the fix for cramped half-width katakana from legacy exports. Named JIS in Japanese Excel.

=DBCS(text)
Full guide, demos & practice file →

DOLLAR

All versions

Converts a number to currency-formatted text like $1,234.57, with accounting parentheses for negatives - made for sentences, not for math.

=DOLLAR(number, [decimals])
Full guide, demos & practice file →

EXACT

All versions

Compares two text strings character for character, case included - the case-sensitive test that the = operator and every lookup function refuse to be.

=EXACT(text1, text2)
Full guide, demos & practice file →

FIND

All versions

Returns the position of text inside text, case-sensitively - the engine behind LEFT/MID/RIGHT extraction combos.

=FIND(find_text, within_text, [start_num])
Full guide, demos & practice file →

FINDB

All versions

Case-sensitive search that returns the match's position in bytes - DBCS characters count as 2 on Japanese, Chinese, and Korean system locales. In English it works exactly like FIND.

=FINDB(find_text, within_text, [start_num])
Full guide, demos & practice file →

FIXED

All versions

Rounds a number to a set number of decimals and returns it as text with thousands commas - great for labels, but invisible to SUM.

=FIXED(number, [decimals], [no_commas])
Full guide, demos & practice file →

LEFT

All versions

Returns the first characters of a text string - the go-to for prefixes, initials, and (with FIND) the first word.

=LEFT(text, [num_chars])
Full guide, demos & practice file →

LEFTB

All versions

Returns the first num_bytes bytes of a string - DBCS characters (Japanese, Chinese, Korean) count as 2 bytes on those system locales. In English it works exactly like LEFT.

=LEFTB(text, [num_bytes])
Full guide, demos & practice file →

LEN

All versions

Counts every character in a string - including the invisible spaces that break lookups - and powers RIGHT+LEN and LEN-SUBSTITUTE tricks.

=LEN(text)
Full guide, demos & practice file →

LENB

All versions

Counts a string's length in bytes - DBCS characters (Japanese, Chinese, Korean) count as 2 on those system locales. In English it returns exactly what LEN does.

=LENB(text)
Full guide, demos & practice file →

LOWER

All versions

Converts every letter in a text string to lowercase - the standard fix for email addresses, usernames, and URLs typed with random capitalization.

=LOWER(text)
Full guide, demos & practice file →

MID

All versions

Extracts characters from the middle of a string - any segment, anywhere, and (with FIND) pieces whose position varies row to row.

=MID(text, start_num, num_chars)
Full guide, demos & practice file →

MIDB

All versions

Extracts a substring by byte position and byte length - DBCS characters count as 2 bytes on Japanese, Chinese, and Korean system locales. In English it works exactly like MID.

=MIDB(text, start_num, num_bytes)
Full guide, demos & practice file →

NUMBERVALUE

Excel 2013+

Converts text to a number with separators you declare yourself - the fix for European-format imports like 1.234,56 on a US system.

=NUMBERVALUE(text, [decimal_separator], [group_separator])
Full guide, demos & practice file →

PHONETIC

All versions

Extracts the furigana reading stored with Japanese text typed via an IME - the key to sorting kanji name lists. Pasted or imported text has no reading, so it returns the text itself.

=PHONETIC(reference)
Full guide, demos & practice file →

PROPER

All versions

Capitalizes the first letter of every word and lowercases the rest - the quick fix for name lists, with one famous gotcha: McDonald becomes Mcdonald.

=PROPER(text)
Full guide, demos & practice file →

REPLACE

All versions

Overwrites a stretch of text by position - start here, replace this many characters. Set num_chars to 0 to insert instead.

=REPLACE(old_text, start_num, num_chars, new_text)
Full guide, demos & practice file →

REPLACEB

All versions

Overwrites a byte-defined region of a string - DBCS characters span 2 byte positions on Japanese, Chinese, and Korean system locales. In English it works exactly like REPLACE.

=REPLACEB(old_text, start_num, num_bytes, new_text)
Full guide, demos & practice file →

REPT

All versions

Repeats text a set number of times - the engine behind in-cell bar charts, star ratings, leading zeros, and dot leaders.

=REPT(text, number_times)
Full guide, demos & practice file →

RIGHT

All versions

Returns the last characters of a text string - last-four digits, file extensions, suffixes, and the leading-zeros padding trick.

=RIGHT(text, [num_chars])
Full guide, demos & practice file →

RIGHTB

All versions

Returns the last num_bytes bytes of a string - DBCS characters (Japanese, Chinese, Korean) count as 2 bytes on those system locales. In English it works exactly like RIGHT.

=RIGHTB(text, [num_bytes])
Full guide, demos & practice file →

SEARCH

All versions

Finds the position of text inside text, ignoring case and supporting ? * wildcards - the everyday 'does it contain' tool.

=SEARCH(find_text, within_text, [start_num])
Full guide, demos & practice file →

SEARCHB

All versions

Case-insensitive, wildcard-friendly search that returns the match position in bytes - DBCS characters count as 2 on Japanese, Chinese, and Korean system locales. In English it works exactly like SEARCH.

=SEARCHB(find_text, within_text, [start_num])
Full guide, demos & practice file →

SUBSTITUTE

All versions

Swaps text by value - replace every occurrence of a string, or just the nth one. Case-sensitive, and the engine behind the count-occurrences trick.

=SUBSTITUTE(text, old_text, new_text, [instance_num])
Full guide, demos & practice file →

T

All versions

Returns the value if it is text, empty text otherwise - a tiny legacy filter that still helps triage imported data.

=T(value)
Full guide, demos & practice file →

TEXT

All versions

Converts a number or date to text in any format you specify - currency, dates, leading zeros - perfect for labels and sentences, but the result is text, not a number.

=TEXT(value, format_text)
Full guide, demos & practice file →

TEXTAFTER

Excel 365

Returns everything after a chosen delimiter - negative instance numbers grab text after the last occurrence.

=TEXTAFTER(text, delimiter, [instance_num], [match_mode], [match_end], [if_not_found])
Full guide, demos & practice file →

TEXTBEFORE

Excel 365

Returns everything before a chosen delimiter - with instance numbers that can count from the end of the text.

=TEXTBEFORE(text, delimiter, [instance_num], [match_mode], [match_end], [if_not_found])
Full guide, demos & practice file →

TEXTJOIN

Excel 2019+

Joins a range of values into one string with a delimiter between each piece, optionally skipping blank cells.

=TEXTJOIN(delimiter, ignore_empty, text1, [text2], ...)
Full guide, demos & practice file →

TEXTSPLIT

Excel 365

Splits one text value into spilled columns, rows, or a 2-D grid at every delimiter - a live, self-updating Text to Columns.

=TEXTSPLIT(text, col_delimiter, [row_delimiter], [ignore_empty], [match_mode], [pad_with])
Full guide, demos & practice file →

TRIM

All versions

Strips leading and trailing spaces and collapses internal runs to a single space - the classic fix for lookups broken by invisible spaces.

=TRIM(text)
Full guide, demos & practice file →

UNICHAR

Excel 2013+

Returns the character for any Unicode code point - bullets, check marks, arrows, trademark signs, and every script Unicode covers.

=UNICHAR(number)
Full guide, demos & practice file →

UNICODE

Excel 2013+

Returns the Unicode code point of a string's first character - the forensic tool for unmasking invisible characters that break lookups.

=UNICODE(text)
Full guide, demos & practice file →

UPPER

All versions

Converts every letter in a text string to capitals - the standard fix for inconsistently typed codes, IDs, and abbreviations.

=UPPER(text)
Full guide, demos & practice file →

VALUE

All versions

Converts a number stored as text into a real number - the antidote to imported columns that SUM totals as zero.

=VALUE(text)
Full guide, demos & practice file →

VALUETOTEXT

Excel 365

Converts any single value to text. Strict mode (format 1) wraps text in quotes, instantly exposing text-numbers and stray spaces that break lookups and sums.

=VALUETOTEXT(value, [format])
Full guide, demos & practice file →

Cube

Functions that query a Power Pivot Data Model or OLAP cube: measures, members, sets, and KPIs for formula-built BI reports.

CUBEKPIMEMBER

Data Model / OLAP

Read KPI value, goal, status, or trend from the model — scorecards without PivotTables.

=CUBEKPIMEMBER(connection, kpi, property)
Full guide, demos & practice file →

CUBEMEMBER

Data Model / OLAP

Validate and display a Data Model member — the reusable building block CUBEVALUE reports are made of.

=CUBEMEMBER(connection, member, )
Full guide, demos & practice file →

CUBEMEMBERPROPERTY

OLAP cubes

Read an attribute of a cube member (city, region, manager) from an Analysis Services cube.

=CUBEMEMBERPROPERTY(connection, member, property)
Full guide, demos & practice file →

CUBERANKEDMEMBER

Data Model / OLAP

Pull the nth item from a sorted cube set — self-updating top-10 leaderboards.

=CUBERANKEDMEMBER(connection, set, rank)
Full guide, demos & practice file →

CUBESET

Data Model / OLAP

Define a sorted set of Data Model members — the foundation of self-updating top-N reports.

=CUBESET(connection, set_expr, , [sort], [by])
Full guide, demos & practice file →

CUBESETCOUNT

Data Model / OLAP

Count the items in a cube set — headline numbers like 'how many active customers' from the Data Model.

=CUBESETCOUNT(set)
Full guide, demos & practice file →

CUBEVALUE

Data Model / OLAP

Pull an aggregated measure from the Data Model, filtered by any members — the engine behind formula-based pivot reports.

=CUBEVALUE(connection, member1, …)
Full guide, demos & practice file →

No matches. We're adding new function guides all the time — tell us which function you need next.

More on the way: we're building guides for every major Excel function — Math, Date & Time, and Statistical categories are coming next. Bookmark this page.

Faster than reading: learn them live

Our Excel Formulas and Functions class teaches the 30 most valuable functions in one hands-on day — in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or live online.

See the Formulas & Functions Class