How to Sort by Date in Google Sheets

Last Modified: May 11, 2023 - 7 min read

Hannah Recker

Here’s how to sort by date in Google Sheets, based on the four methods detailed below.

Sorting by date in Google Sheets helps you find and organize your data more efficiently. This makes your data easier to analyze.

The following guide will demonstrate the best ways to sort by date in Google Sheets, based on real examples and use cases.

Video Walkthrough: How to Sort by Data in Google Sheets

Sorting by Date in Google Sheets: Top 4 Methods

Method 1: Sort Sheet Option

If your data is in a single column, the Sort sheet option is a quick way to sort by date.

Let’s use a sample dataset to show how to use the Short sheet option. The data below was pulled from HubSpot into Google Sheets with Coefficient.

Read our blog for a full walkthrough on how to connect HubSpot to Google Sheets.

Now onto the example. Let’s sort the dates within the Create Date column.

Ensure all the values in the column are in a valid date format before sorting to avoid errors.

To do this, select your cell range (F3:F18), click on the Data tab in the top menu, and choose Data validation.

In the Data validation rules side pane, set Is valid date as your criteria. Then click Done.

An error message will appear if the values are not valid dates or if your data is in an incorrect format.

Next, click on the View option on the top menu. Hover your mouse over Freeze, and select the header row to freeze it in place.

Select a cell within the column containing the dates you want to sort. Then click on Data > Sort sheet > Sort sheet by column F (A to Z).

The Create date column or column F should now show the earliest date to the latest.

Select the Sort sheet by column F (Z to A) option if you want to organize the column from the latest to the earliest date.

You can use this same sorting option to alphabetize in Google Sheets.

The Sort sheet option is a quick and easy method to sort by date, especially when the dates are contained in a single column.

Method 2: SORT Function

The SORT function is another way to sort by date in Google Sheets. With the function, you can sort single or multiple columns as part of a formula.

The SORT function also makes the sorted data dynamic. If your original dataset changes, the output of the SORT function is automatically updated.

Here’s how to leverage the SORT function. First, let’s add a blank column next to the dates we want to sort.

Next, enter the SORT formula below in cell G3.

=SORT(F3:F18,1,TRUE)

The function instantly sorts the dates from the earliest to the latest.

The SORT function above consists of three arguments:

  • The cell range you want to sort (F3:F18)
  • The column to sort, relative to the given range (1)
  • The order for sorting the data, in this case ascending order (TRUE)

You can also sort multiple columns into a single column. To demonstrate this, let’s sort the data in adjacent columns (Create date and Close date).

Add two blank columns beside the Close date column. Enter this formula (in cell H3) to sort both columns based on the Create date column:

=SORT(F3:G18,1,TRUE)

Hit Enter and you should see the blank columns populated with the sorted Create Date and Close Date columns.

The SORT function can only return output to cells that are empty. Otherwise, Google Sheets will return an error message.

Deleting or changing the cells where you applied your SORT formula will result in errors. To change the cells, you must convert them to values before editing them.

Method 3: Sort Range Tool

You can also use the sort range tool to sort dates in Google Sheets. This is a good option if you only need to sort the dates once, and if you don’t need your dates to be dynamic.

Here’s how the sort range tool works. First, select the data for sorting (F3:G18). Then click on Data in the top menu.

Hover your mouse over the Sort range option in the dropdown list. Click on Advanced range sorting options.

If your selected data has a column header, check the Data has header row option in the Sort range dialog box. If not, leave this unchecked.

For this example, select Column F as the Sort by option. Then choose A→Z to sort your data in ascending order, or Z→A to organize the column in descending order. Then click Sort.

spreadsheet ai
Free AI-Powered Tools Right Within Your Spreadsheet

Supercharge your spreadsheets with GPT-powered AI tools for building formulas, charts, pivots, SQL and more. Simple prompts for automatic generation.

Sort multiple columns by clicking the Add another sort column option before selecting the Sort button.

And voila — the Sort Range Tool sorts the column by date.

Method 4: Filters

Another way to sort by date in Google Sheets is to create filters.

To set up filters, select the column headers with the data you want to sort. Then click on Data > Create a filter.

To sort your column data by date, click on the inverted triangle icon within the cell.

Then select Sort A→Z to organize the data under the column from the earliest to the latest date.

To turn off the filter, choose Data and then Remove filter. It’s that simple.

Additional Examples: Sort by Month and Sort by Date with ARRAYFORMULA

Below are two additional options to sort by date in Google Sheets. Let’s use an array formula to sort months as text.

We’ll use a simple table, such as the dataset below, with the months of the year in random order.

Use this SORT array formula in cell B2:

=SORT(A2:A13,MONTH(A2:A13&1),1)

The formula sorts the months in the proper order.

In the formula, the MONTH function has a range as an input. This produces an array of numbers, 1 to 12 representing each month, sorted in ascending order.

What if you want to sort specific dates based on the month? There’s a formula for that too. Take the sample table below.

To sort the dates in the appropriate order, enter the formula below in cell B2.

=SORT(A2:A,MONTH(A2:A) ,TRUE)

You’ll see that your data is now sorted starting with January (1). The MONTH function sorts the dates in your range from earliest to latest, and the SORT function creates a new array in column B based on that list.

Common Mistakes When Sorting by Date in Google Sheets

Below are common mistakes you might make when sorting by date in Google Sheets.

  • Incorrect formatting. Ensure the cells containing the dates are formatted as “Date” or “Date Time.” If the cells are formatted as “Text,” the sorting function won’t work properly.
  • Inconsistent ordering. If the dates in your sheet aren’t ordered in the same way, the sorting function might not work. For example, if some dates are ordered mm/dd/yyyy and others are ordered dd/mm/yyyy, the sorting could be erroneous.
  • Blank cells. If your sheet contains blank cells, the sorting function may treat them as the earliest date in your dataset. To avoid this, use the Sort sheet by column function and choose the Sort sheet A→Z option. This will sort blank cells at the bottom of the column.

If your dataset fails to sort properly, chances are one of these mistakes occurred before sorting.

It’s Easy to Sort by Date in Google Sheets

Sorting by date helps you analyze your spreadsheet data faster. The methods for sorting by date in Google Sheets are all straightforward, so you can easily organize your data in a few clicks.

Coefficient makes data sorting, reporting, and analysis in Google Sheets even easier with one-click data connectors.

Get started with Coefficient for free right now to pull data from your business systems into Google Sheets automatically.

Read More of Our ‘How-To’ Google Sheets Articles…

Sync Live Data into Your Spreadsheet

Connect Google Sheets or Excel to your business systems, import your data, and set it on a refresh schedule.

Try the Spreadsheet Automation Tool Over 350,000 Professionals are Raving About

Tired of spending endless hours manually pushing and pulling data into Google Sheets? Say goodbye to repetitive tasks and hello to efficiency with Coefficient, the leading spreadsheet automation tool trusted by over 350,000 professionals worldwide.

Sync data from your CRM, database, ads platforms, and more into Google Sheets in just a few clicks. Set it on a refresh schedule. And, use AI to write formulas and SQL, or build charts and pivots.

Hannah Recker Growth Marketer
Hannah Recker was a data-driven growth marketer before partying in the data became a thing. In her 12 years experience, she's become fascinated with the way data enablement amongst teams can truly make or break a business. This fascination drove her to taking a deep dive into the data industry over the past 4 years in her work at StreamSets and Coefficient.
350,000+ happy users
Wait, there's more!
Connect any system to Google Sheets in just seconds.
Get Started Free

Trusted By Over 20,000 Companies