How to Unsort in Google Sheets – The 2 Best Ways

How to Unsort in Google Sheets

Google Sheets is a powerful spreadsheet software utilizing rows and columns to create a grid consisting of multiple datasets.

In this grid of potentially huge datasets, it can be quite easy even for the best data analysts to be confused with the flood of data.

That is why Google Sheets is equipped with features that make almost everything related to data handling possible.

One of these features is sorting data in Google Sheets.

The opposite of sorting data is unsorting data in Google Sheets. In this tutorial, I will show you how to unsort in Google Sheets.

How to Unsort in Google Sheets

To unsort in Google Sheets you can use the undo command or use the index column. To unsort in Google Sheets using the undo command use the command “Ctrl + Z” or the undo button (arrow). To unsort using an index column add an additional column and number it.

How to Unsort in Google Sheets
How to Unsort in Google Sheets

Unsorting in Google Sheets Video Tutorial

2 Ways to Unsort in Google Sheets

1. Unsort Using the Undo Command in Google Sheets

The simpler way of reverting any sorting that you’ve done to a dataset is by using the ‘Undo Command’ more commonly familiar as “Ctrl + Z”.

As it is useful not only for undoing any mistakes but technically to undo any and all changes that have been made recently from its point of activation.

As an example, check out the dataset below.

Sample dataset 
Sample dataset 

We can try sorting column A by right-clicking on its header and clicking ‘Sort sheet A to Z’.

Sample dataset sorted through column A
Sample dataset sorted through column A

As you can see, the other columns’ rows have been rearranged accordingly.

This is because when you sort a column in a dataset it sorts the whole dataset based on the criteria to which the column is subjected.

Now, this may not be what you expected and this is where the Undo command does its best to unsort in Google Sheets.

To unsort, simply use the Undo command. There are 3 ways to initiate the Undo command.

One way is to click the Undo button.

The UNDO button is located below the Google Sheets logo
The UNDO button is located below the Google Sheets logo

The other method is to go to the ‘Edit’ menu and select ‘Undo’.

The UNDO option as seen in the ‘Edit’ menu
The UNDO option as seen in the ‘Edit’ menu

The last means of initiating the Undo command, and the most popular, is to hit “CTRL + Z” on a PC or “CMD + Z” on a Mac.

In doing so, we’ll be able to showcase how to unsort in Google Sheets.

Showing the dataset reverted to its original state
Showing the dataset reverted to its original state

The downside of relying on the Undo command to unsort in Google Sheets is that it can only be done in the same session when you’ve committed the changes that you wish to revert.

Otherwise, you won’t be able to do it.

An alternative to that is to restore the version of the spreadsheet to a state before any changes were made to your dataset.

That said, if any other changes were made to other parts of the spreadsheet, they will be reverted too.

2. Unsort Using the Index Column in Google Sheets

Now, if you are unable to use the Undo command because you made the changes at a different time and you are unwilling to restore an older version of your spreadsheet, you may instead unsort using an index column.

Take note that this is different from the INDEX function.

An index column serves as an identifier to distinguish one row from another.

It can be as simple as a column numbering each row from one to one hundred.

It can also be the column containing the dates specifying the exact time when the rows were filled out (as long as the dates are inputted in either ascending or descending order).

An example of an INDEX column
An example of an INDEX column

The difference between this latter method versus the former is that, unlike the Undo command, you’ll have to have an existing index column before doing any changes.

Once that preparation is done, you may sort your dataset however you like and you may still revert any changes done.

As an example, I’ve sorted the dataset with an index column below.

The sample dataset with an index column has been sorted
The sample dataset with an index column has been sorted

The dataset has been rearranged as I’ve sorted column B from A to Z. This caused the index column to be shuffled as well.

To unsort this, just right-click on your index column’s header, and select ‘Sort sheet A to Z’.

This will force your whole dataset to rearrange itself back to its original state when the index column was arranged from A to Z (ascending order).

The unsorted sample dataset with an index column
The unsorted sample dataset with an index column

Note: If you have a header row, you can easily move it back to the top if it gets displaced.

Alternatively, just put the number zero (0) in place of the word “INDEX” as the index column’s header.

Other than creating an index column where you type a range of numbers (1 to 100, for example) you may also use existing columns in your dataset as the index column.

An example will be if you have a spreadsheet with data taken in from Google Forms.

The sheet associated with the form will have a column indicating the date and time when the form is filled for a particular row or entry.

A sample similar to spreadsheets associated with Google Forms
A sample similar to spreadsheets associated with Google Forms

These dates will always get to the spreadsheet in ascending order (older ones first) until you sort it depending on the criteria that you require.

Sorted sample spreadsheet
Sorted sample spreadsheet

As such, to unsort sorted data with such a column, you just need to right-click on that column’s header and select ‘Sort sheet A to Z’.

This will put it back to its original state before being sorted, thanks to the index column.

Frequently Asked Questions about How to Unsort in Google Sheets

How many times can I undo to unsort in Google Sheets?

Google Sheets saves up to 100 actions at a time before it will need to recalculate and adjust your saved actions.

My colleague made a mistake in sorting our group spreadsheet, how can I unsort in Google Sheets?

Keep in mind that you can only undo the edit that you’ve made, including unsort in Google Sheets. You can reach out to your colleague to undo the changes he has done, otherwise, your only option left is to restore the last unsorted version of your spreadsheet.

Conclusion on How to Unsort in Google Sheets

There are two ways to unsort in Google Sheets. One is to use the Undo command in the same session using “Ctrl + Z” or the undo button (arrow). The other way is to create an index column that serves as a marker for the original sorting by numbering each cell.