TRANSPOSE function
Flips a range so its rows become columns and its columns become rows.
Available in All versions of Excel. In Microsoft 365 and Excel 2021+ it spills automatically; in older versions select the output range and confirm with Ctrl+Shift+Enter.
In every Excel versionWorks in Google Sheets
Syntax
TRANSPOSE(array)| Argument | What it means | |
|---|---|---|
array | Required | The range or array to flip. |
Returns: The same values with rows and columns swapped. A range of R rows and C columns becomes C rows and R columns.
How TRANSPOSE works
TRANSPOSE turns a table on its side: what ran down the page now runs across, and vice versa. It is the formula version of Paste Special > Transpose, with one big difference - the result stays linked to the source, so when a value in the original changes the flipped copy changes too.
In Microsoft 365 and Excel 2021 or later you type the formula in one cell and the result spills into the right shape automatically. In Excel 2019 and earlier it is a legacy array formula: you must first select an output range of exactly the flipped size (for example 2 rows by 4 columns for a 4-by-2 source), type the formula and press Ctrl+Shift+Enter. Empty source cells come back as 0, and formatting is not copied.
Beyond reshaping reports, TRANSPOSE is needed in matrix maths with MMULT, where one of the ranges must be turned around before the two can be multiplied.
Examples
1Turn a vertical table horizontal
| A | B | C | D | E | F | G | |
|---|---|---|---|---|---|---|---|
| 1 | Month | Sales | Month | Jan | Feb | Mar | |
| 2 | Jan | 8200 | Sales | 8200 | 9150 | 10400 | |
| 3 | Feb | 9150 | |||||
| 4 | Mar | 10400 |
A 4-row by 2-column table becomes 2 rows by 4 columns, spilling into D1:G2.
2Headers into a column
| A | B | C | D | E | F | G | |
|---|---|---|---|---|---|---|---|
| 1 | Region | Q1 | Q2 | Q3 | Q4 | Q1 | |
| 2 | North | 12500 | 14200 | 13900 | 16100 | Q2 | |
| 3 | South | 9800 | 10400 | 11250 | 12030 | Q3 | |
| 4 | East | 7600 | 8150 | 8900 | 9420 | Q4 |
The quarter headings that run across row 1 are listed downwards, ready to use as row labels in another report.
3Invoice total with matrix multiplication
| A | B | C | D | E | |
|---|---|---|---|---|---|
| 1 | Item | Qty | Unit price | ||
| 2 | Paper | 3 | 12.5 | 117.5 | |
| 3 | Toner | 5 | 4 | ||
| 4 | Folders | 2 | 30 |
Result: 117.5
MMULT needs a row times a column, so the quantities are transposed into a row. The result is 3x12.5 + 5x4 + 2x30 = 117.5 (the same as SUMPRODUCT).
Common errors and how to fix them
| Error | Why it happens | Fix |
|---|---|---|
#SPILL! | The cells needed for the flipped result are not empty. | Clear the output area or move the formula. |
#VALUE! | In older Excel the formula was entered with plain Enter, or the selected output range is the wrong size. | Select the correctly sized range and press Ctrl+Shift+Enter. |
Tips
- Blank source cells appear as 0; use
=TRANSPOSE(IF(A1:B4="", "", A1:B4))to keep them blank. - If you only need a one-off flipped copy with formatting, Paste Special > Transpose is simpler.
- TOROW and TOCOL flatten a range into a single row or column instead of flipping it.
Questions
Why does TRANSPOSE show only one value in Excel 2016?
Older versions need a legacy array formula: select the whole output range first, type the formula, then press Ctrl+Shift+Enter.
Does TRANSPOSE keep the link to the original data?
Yes. Unlike Paste Special > Transpose, the formula updates when the source changes.
Google Sheets
TRANSPOSE also exists in Google Sheets and works the same way for everyday use, so the examples above work there too.
TRANSPOSE in other languages
In a non-English version of Excel the function has a local name. Excel translates formulas automatically when a file is opened in another language.
| Language | Function name |
|---|---|
| Czech | TRANSPOZICE |
| Danish | TRANSPONER |
| Dutch | TRANSPONEREN |
| Finnish | TRANSPONOI |
| German | MTRANS |
| Hungarian | TRANSZPONÁLÁS |
| Italian | MATR.TRASPOSTA |
| Norwegian (Bokmål) | TRANSPONER |
| Polish | TRANSPONUJ |
| Portuguese (Brazil) | TRANSPOR |
| Portuguese (Portugal) | TRANSPOR |
| Russian | ТРАНСП |
| Spanish | TRANSPONER |
| Swedish | TRANSPONERA |
| Turkish | DEVRİK_DÖNÜŞÜM |