Files & formats

How to sort a column in Google Sheets and keep rows together

The short answer

Select every column in the table, then open Data → Sort range → Advanced range sorting options. Choose the column that should set the order. Sheets moves the cells in each selected row together, so include every column that belongs to the record.

Related sourcesGoogle

01Select the table you want to sort

Section link

On a computer, highlight the header and all the data rows you want to reorder. In a table with Name, Due date and Status, select all of those columns even if you only want to sort by Due date. Leave any separate table or notes that should stay fixed outside the selection.

02Pick the column and keep the header in place

Section link

Open Data → Sort range → Advanced range sorting options. If you included column titles, check Data has header row. Select Due date in the example, choose the direction and click Sort. For equal dates, use Add another sort column before sorting if you want a second rule, such as Name.

03Confirm a record moved as a unit

Section link

Before sorting, note a distinctive name and the date and status beside it. Afterward, find that name and check the same date and status moved with it. Sort range is useful when another table shares the same sheet because it leaves cells outside the selected rectangle in place.

04Recover after sorting only part of a table

Section link

Undo if you just sorted one column and the records no longer match. If you discover the mix-up later and have edit access, open Version history and find a version from before the sort. Make a copy of that version to inspect the original records without rolling back your collaborators’ newer edits.

Sources & further reading