How to sort a list without mixing up rows
Sorting puts a list in order: highest sales first, earliest due date first, or names A to Z. It is one of the quickest ways to answer “Who sold the most?” or “What is due next?” It is also the easiest way to wreck a spreadsheet. If only one column is sorted, names and numbers get separated, and the sheet looks fine while being completely wrong. This guide shows how to sort safely.
The example
A sales team’s monthly results are listed in the order people were hired. The manager wants a leaderboard with the highest sales at the top.
| Row | A: Representative | B: Sales | After sorting B, high to low | |
|---|---|---|---|---|
| 1 | Representative | Sales | Representative · Sales | |
| 2 | Alex | 4200 | Sarah · 9500 | |
| 3 | Sarah | 9500 | Elena · 7800 | |
| 4 | David | 3100 | Carlos · 6200 | |
| 5 | Elena | 7800 | Alex · 4200 | |
| 6 | Carlos | 6200 | David · 3100 |
Notice that each name travels with its own number. Sarah still has 9500 after the sort. That is the whole goal.
Step by step
- Click any cell inside the table, or select the whole table from A1 to B6. Do not select only column B.
- Open the sort tool. In Excel it is Data → Sort. In Google Sheets it is Data → Sort range. In the FreeJobTools trainer, it is the 🔀 Sort button above the sheet.
- Tell it the table has a header row. Tick the box labelled “My data has headers” or “Data has header row.” This keeps “Representative” and “Sales” in row 1 instead of sorting them in with the names.
- Choose the column to sort by: Sales.
- Choose the direction. Descending (Z → A, largest to smallest) puts the top seller first. Ascending (A → Z, smallest to largest) does the opposite.
- Apply the sort and check one row. Pick a name you know, such as Sarah, and confirm her number came with her.
Common mistakes
- Sorting a single column. If you select only B2:B6 and sort, the numbers move but the names stay put. Alex would end up beside 9500. Excel usually warns you and offers to “expand the selection.” Say yes. If it has already happened, undo immediately with Ctrl+Z (Cmd+Z on a Mac).
- The heading gets sorted into the data. If the header box is not ticked, “Sales” may land at the bottom of the list. Undo and sort again with the header option on.
- Numbers stored as text sort strangely. Text sorts character by character, so “100” comes before “25”, the same way “apple” comes before “banana.” If a sort of numbers looks wrong, check that the cells hold real numbers.
- A blank row splits the table. Spreadsheets treat a fully empty row as the end of the table. Rows below it will not be sorted. Remove blank rows inside the list first.
- Sorting a shared sheet others rely on. Sorting changes the original order for everyone. If the original order matters, for example the order in which orders arrived, add a numbered column first so you can sort back. Or make a copy of the sheet.
Questions first-time users ask
Can I sort by two columns?
Yes. In the sort window, add a second level. For example, sort by Region A to Z, then by Sales from largest to smallest. The result groups people by region with each region’s top seller first.
What is the difference between sorting and filtering?
Sorting changes the order of every row. Filtering hides the rows that do not match, for example showing only the North region, without changing their order. Turning a filter off brings every row back.
Will my formulas break after sorting?
Formulas that use cells in their own row, such as =B2*C2, move with the row and keep working. Formulas elsewhere that point at a fixed cell such as B2 will now see whichever value is in B2 after the sort. Check summary formulas after a big sort.
How do I find the top seller without sorting?
=MAX(B2:B6) returns the highest number, 9500, without moving anything. Sorting is better when you need the whole ranked list.
Practice it
What you will see in the trainer
The Leaderboard Data Sorting guided round uses the same team and numbers shown above in A1:B6. Open Sort, choose column B (Sales), choose Descending, and keep the header-row option checked. Sarah and 9500 should be first; David and 3100 should be last.
“Your turn” gives you new names and numbers. Sort the entire A1:B6 table again so each representative stays beside their own sales figure. The separate pivot-table lesson builds a regional summary when you feel ready.
Related guides: sorting and summarizing workplace data · counting order statuses · looking up values · all guides