You can find the total seconds between two times in Google Sheets in many ways. We’ll cover the two easiest.
Contents
Preparation – Properly Format Your Times
Before you use the formulas in this tutorial, ensure your times are valid. If the times are invalid, they aren’t numbers, so these steps won’t work.
As shown above, you can use the ISDATE function to check each time.
Calculations – Find the Difference Between Two Times in Seconds
You can find the seconds once your data is ready using these easy formulas. Each technique has different advantages.
First formula: =ROUND((B2-A2)*24*60*60)
The most simple formula simple subtracts the starting time from the ending time. When you subtract two times in Google Sheets, the result is the number of days between them. Since you are looking for seconds instead of days, multiply this difference by 24
to get to hours, by 60
to arrive at minutes, then by 60
to arrive at seconds.
Second formula: =TEXT(B3-A3,"[S]")&" seconds")
This next formula converts the result to a text string using the TEXT function. Using a text string allows you to add the unit to the end of the result to make it clear to the spreadsheet reader. So, as seen in the image above, the result is shown as 80548 minutes instead of just 80,548.00.
⚠️ Be sure to add the square brackets around the [S]
if you are calculating a longer duration. These brackets change the format from a point in time to a duration. This allows the seconds to exceed 60.
Practice – Get a Copy of the Template
Make a copy of this template to see the examples in a live Google Sheet.
Advanced – Use TIMEDIF for Other Time Units
If you want a more complex output, such as years, weeks, or months, consider using the TIMEDIF add-on.
TIMEDIF will calculate the duration between two times without using any formulas. Once you install the add-on, pick the units you want, and it will do the rest.
Related Tutorials
-
Understanding Data Types in Google Sheets
Learn about the different types of data you can use in a spreadsheet.
-
DATEDIF Function – Google Sheets
The DATEDIF function calculates the difference between two days. You can return the difference in days, months, years, or combinations. Whereas the DAYS function will only return days, this function has multiple output options. The input for this function needs to be either surrounded by quotes or a cell reference. If your days, months, and…
-
DAYS Function – Google Sheets
The DAYS function calculates the number of days between two dates.
-
Date Functions – Using Dates and Times in Google Sheets
Learn the nuances of working with dates and times in Google Sheets.
-
How dates and times work in Google Sheets
Contents1 How Dates Work1.1 Using Dates in Formulas1.2 Subtracting Two Dates: Example 11.3 Subtracting Two Dates: Example 21.4 The Beginning of Time2 How Times Work3 How Dates and Times Work Together3.1 Live Examples in Sheets4 Related Tutorials How Dates Work Though it may not be obvious initially, spreadsheets store dates as numbers instead of text.…