Excel time from seconds

Return to Excel Formulas List

Download Example Workbook

Download the example workbook

This tutorial will demonstrate how to convert seconds to days, hours, and minutes in Excel and Google Sheets.

convert seconds to minutes hours Main Function

Convert Seconds to Minutes and Seconds

First divide the number of seconds by 86400 (the number of seconds in a day).

=$B3/86400

MinutesSeconds

Once you have done this, you will get the time value as a number. To display the time value as a valid time (i.e. in minutes and seconds) format the cell with custom formatting.

  1. Highlight the cells you wish to format eg: D3:D10.
  2. In the Ribbon, select Home > Number and then click on the little arrow on the right-hand side of the number group.

Number Format

  1. This brings up the Format Cells dialog box.

Number Format 2

  1. Click on Custom at the bottom of the list, and then type mm:ss into the custom format text box.

Number Format 3

  1. Click OK.

Convert to Hours, Minutes and Seconds

Use hh:mm:ss format to display in hours, minutes, and seconds.

HoursMinutesSeconds

Convert to Days, Hours, Minutes and Seconds in Excel

To display days as well, you can create custom formatting like below.

DaysHoursMinutesSeconds

Convert Seconds to Minutes and Seconds in Google Sheets

As with Excel, the first step to converting elapsed second to time is to divide the value by 86400.

=$B3/86400
  1. To format the cells for mm:ss, select Format > Number > More Formats > More date and time formats from the Menu.

Google 01

Google 02

  1. Delete the 3 formats shown by clicking on each format and selecting Delete.

Google 03

  1. Scroll down the list and find a format with minutes and seconds.

Google 04

  1. Click on that format to add it to the bar at the top of the custom box.

Google 5

  1. Delete the Hour format from the custom format.Google 06
  2. Click Apply to apply the formatting to your worksheet.Google 07

Convert to Hours, Minutes and Seconds in Google Sheets

You use the same formula in Google Sheets as you do in Excel to convert the seconds to time by dividing the value by 86400.

=$B3/86400

Google 08

You then use custom formatting to display the hours as well as the minutes and seconds.

Google 09

Convert to Days, Hours, Minutes and Seconds in Google Sheets

You use the same formula in Google Sheets as you do in Excel to convert the seconds to time by dividing the value by 86400.

=$B3/86400

You then use custom formatting to display the days as well as the hours, minutes and seconds.

  1. Delete the formatting in the Custom date and time formats box, and then click on the drop-down box to the right of the custom format box to display all the date and time options.

Google 10

  1. Select Day and then type “days’, select Hour and then type “hours”, select Minute and then type “minutes” and then select Second and type “seconds”

Google 11

  1. Click Apply.

Google 12

Use Calculations and Formatting to Convert Seconds to Minutes and Seconds in Microsoft Excel

by Avantix Learning Team | Updated April 6, 2021

Applies to: Microsoft® Excel® 2013, 2016, 2019 and 365 (Windows)

Although you can convert seconds to minutes and seconds in Excel, it can be a bit tricky to convert and display times in combined units (hours, minutes and seconds). Because time is calculated in Excel as a fraction of a day, you can convert fractions to appropriate time increments by combining calculations and custom number formatting.

Let’s say you have entered 80 in a cell (representing 80 seconds) and you want to convert it to the equivalent of minutes and seconds. Since there are 60 seconds in a minute, you may try to divide it by 60, but the result will be a minute and a fraction, not minutes and seconds (in this case, 1.34). However, 80 seconds is actually 1:20 or 1 minute and 20 seconds.

To convert seconds to minutes and seconds, you can divide the seconds by the total number of seconds in a day and then apply the time custom number format to display as minutes and seconds.

Recommended article: 10 Great Excel Pivot Table Shortcuts

Do you want to learn more about Microsoft Excel? Check out our virtual classroom or live classroom Excel courses >

Applying a custom number format for minutes and seconds

To apply custom number formatting for minutes and seconds, enter or select a time format using the Format Cells dialog box:

  1. Select the cells, columns or rows to which you want to apply a custom number format.
  2. Press Ctrl + 1 or right-click and select Format Cells. A dialog box appears.
  3. Click the Number tab.
  4. Click Custom in the category on the left.
  5. In the General Area, enter mm:ss or click it in the list.
  6. Click OK.

Below is the Format Cells dialog box with the minutes and seconds custom format:

Microsoft Excel Format Cells dialog box with custom time format for minutes and seconds.

There are several time formats in this dialog box. Codes include h for hour, m for minute and s for seconds.

Converting seconds to minutes and seconds

To convert seconds entered in cells to minutes and seconds, divide the seconds by the total number of seconds in a day (60 multiplied by 60 multiplied by 24) and then apply the time custom number format of mm:ss (minutes and seconds).

In the following example, we have entered seconds in column A that we want to convert to minutes and seconds in column B:

Excel seconds entered in column to convert to minutes and sections.

To convert seconds entered in column A to minutes and seconds in column B:

  1. Click in B2.
  2. Enter the formula =A2/(60*60*24) and press Enter. Keep in mind that there are 60 seconds in a minute, 60 minutes in an hour and 24 hours in a day.
  3. Click in B2, click the bottom right corner handle and drag down to row 18 to copy the formula down.

Column B appears as follows with the General format applied:

Excel calculation to convert seconds to minutes and seconds.

To format column B as minutes and seconds:

  1. Select column B.
  2. Press Ctrl + 1 or right-click and select Format Cells. A dialog box appears.
  3. Click the Number tab.
  4. Click Custom in the category on the left.
  5. In the General Area, enter mm:ss or click it in the list.
  6. Click OK.

Column B appears as follows with the mm:ss format applied:

Excel format fractions ad minutes and seconds.

Here’s another example. In this worksheet, we’ve entered start times and end times. The times are entered as hours:minutes:seconds and then AM or PM (with a space before AM or PM):

Microsoft Excel worksheet with start times and end times.

To calculate the time difference between the two columns:

  1. Click in C2.
  2. Enter the formula =B2-A2 and press Enter.
  3. Click in C2, click the bottom right corner handle and drag down to row 6 to copy the formula down. Excel calculates the difference as a fraction.
  4. You may need to select column C and apply the General format to view the result as a fraction. Click the Home tab in the Ribbon and in the Number group, select General from the drop-down menu of formats.

The values in column C appear as fractions with the General format applied as follows:

Microsoft Excel calculation of time difference between start time and end time with fractions.

To format column C as minutes and seconds:

  1. Select column C.
  2. Press Ctrl + 1 or right-click and select Format Cells. A dialog box appears.
  3. Click the Number tab.
  4. Click Custom in the category on the left.
  5. In the General Area, enter mm:ss or click it in the list.
  6. Click OK.

Column C appears as follows with the mm:ss format applied:

Microsoft Excel applying time formatting to fractions.

However, in the above example, there is a problem with row 6. The time differential is in hours, minutes and seconds so let’s change the format for column C to hh:mm:ss.

Below is the final result with hh:mm:ss formatting applied to column C::

Microsoft Excel worksheets with times formatted as hours, minutes and seconds.

There are other functions and calculations you can use to calculate time but the strategies we’ve used here are useful for many scenarios. Working with time can be tricky and if start times and end times are not entered correctly, you won’t be able to calculate time differences.

Subscribe to get more articles like this one

Did you find this article helpful? If you would like to receive new articles, join our email list.

More resources

How to Remove Duplicates in Excel (3 Easy Ways)

How to Merge Cells in Excel (4 Ways with Shortcuts)

How to Combine Cells in Excel Using Concatenate (3 Ways)

How to Change Commas to Decimal Points in Excel and Vice Versa (5 Ways)

How to Replace Blank Cells in Excel with Zeros (0), Dashes (-) or Other Values

Related courses

Microsoft Excel: Intermediate / Advanced

Microsoft Excel: Data Analysis with Functions, Dashboards and What-If Analysis Tools

Microsoft Excel: Introduction to Visual Basic for Applications (VBA)

VIEW MORE COURSES >

Our instructor-led courses are delivered in virtual classroom format or at our downtown Toronto location at 18 King Street East, Suite 1400, Toronto, Ontario, Canada (some in-person classroom courses may also be delivered at an alternate downtown Toronto location). Contact us at info@avantixlearning.ca if you’d like to arrange custom instructor-led virtual classroom or onsite training on a date that’s convenient for you.

Copyright 2023 Avantix® Learning

Microsoft, the Microsoft logo, Microsoft Office and related Microsoft applications and logos are registered trademarks of Microsoft Corporation in Canada, US and other countries. All other trademarks are the property of the registered owners.

Avantix Learning |18 King Street East, Suite 1400, Toronto, Ontario, Canada M5C 1C4 | Contact us at info@avantixlearning.ca

Explanation 

In the Excel date system, one day is equal to 1, so you can think of time as fractional values of 1, as shown in the table below:

Hours Fraction Minutes Seconds Value Time
1 1/24 60 3600 0.04167 1:00
3 3/24 180 10800 0.125 3:00
6 6/24 360 21600 0.25 6:00
12 12/24 720 43200 0.5 12:00
18 18/24 1080 64800 0.75 18:00
24 24/24 1440 86400 1.0 21:00

Since there are 24 hours in a day, 60 minutes in each hour, and 60 seconds in each minute, you need to divide by 24 * 60 * 60 = 86400 in order to convert decimal seconds to a value that Excel will recognize as time. After dividing by 86400, you can apply a time format of your choice, or use the result in a math operation with other dates or times.

In the example, since B11 contains 43200 (representing 43200 seconds, or a half day) the result is 43200/86400 = 0.5. Once a time format like h:mm or [h]:mm is applied, Excel will display 12:00.

Displaying a time duration

To display hours that represent a duration longer than 24 hours, minutes in durations longer than 60 minutes, or seconds in durations over 60 seconds, you’ll need to adjust the number format by adding square brackets.

[h]  // for hours greater than 24
[m]  // for minutes greater than 60
[s]  // for seconds greater than 60

The brackets tell to Excel the time is a duration, and not a time of day.

Note: to use square brackets, you’ll need to create and apply a custom number format. Select cells, then go to Format Cells (Control + 1) > Number > Custom.

Содержание

  • Преобразование секунд в минуты и секунды в Excel
  • Преобразование в часы, минуты и секунды в Excel
  • Преобразование в дни, часы, минуты и секунды в Excel
  • Преобразование секунд в минуты и секунды в Google Таблицах
  • Преобразование в часы, минуты и секунды в Google Таблицах
  • Преобразование в дни, часы, минуты и секунды в Google Таблицах

Скачать пример рабочей книги

Загрузите образец книги

В этом руководстве будет показано, как преобразовать секунды во время в дни, минуты и часы в Excel и Google Таблицах.

Первый шаг к преобразованию прошедшей секунды во время — это разделить значение на 86400. Причина в том, что в сутках 86400 секунд, то есть: в 24 часах.

Как только вы это сделаете, вы получите значение времени в виде числа. Чтобы отображать значение времени как действительное время, то есть в минутах и ​​секундах, вам необходимо отформатировать ячейку с помощью настраиваемого форматирования.

  1. Выделите ячейки, которые вы хотите отформатировать, например: D3: D10.
  2. На ленте выберите Главная> Номер и затем щелкните маленькую стрелку справа от группы номеров.

  1. Откроется диалоговое окно «Формат ячеек».

  1. Нажмите на Обычай внизу списка, а затем введите мм: сс в текстовое поле настраиваемого формата.

  1. Нажмите Ok.

Преобразование в часы, минуты и секунды в Excel

Вы используете ту же формулу для преобразования секунд во время, разделив значение на 86400.

Затем вы используете настраиваемое форматирование для отображения часов, а также минут и секунд.

Преобразование в дни, часы, минуты и секунды в Excel

Вы используете ту же формулу для преобразования секунд во время, разделив значение на 86400.

Затем вы используете настраиваемое форматирование для отображения дней, а также часов, минут и секунд.

Преобразование секунд в минуты и секунды в Google Таблицах

Как и в случае с Excel, первым шагом к преобразованию прошедшей секунды во время является деление значения на 86400.

  1. Чтобы отформатировать ячейки для мм: сс, Выбрать Формат> Число> Дополнительные форматы> Дополнительные форматы даты и времени из меню.

  1. Удалите 3 показанных формата, щелкнув каждый формат и выбрав Удалить.

  1. Прокрутите список вниз и найдите формат с минутами и секундами.

  1. Щелкните этот формат, чтобы добавить его на панель вверху настраиваемого поля.

  1. Удалите формат «Час» из настраиваемого формата.
  2. Нажмите Применить, чтобы применить форматирование к вашему рабочему листу.

Преобразование в часы, минуты и секунды в Google Таблицах

Вы используете ту же формулу в Google Таблицах, что и в Excel, чтобы преобразовать секунды во время, разделив значение на 86400.

Затем вы используете настраиваемое форматирование для отображения часов, а также минут и секунд.

Преобразование в дни, часы, минуты и секунды в Google Таблицах

Вы используете ту же формулу в Google Таблицах, что и в Excel, чтобы преобразовать секунды во время, разделив значение на 86400.

Затем вы используете настраиваемое форматирование для отображения дней, а также часов, минут и секунд.

  1. Удалите форматирование в поле «Пользовательские форматы даты и времени», а затем щелкните раскрывающийся список справа от поля пользовательского формата, чтобы отобразить все параметры даты и времени.

  1. Выбирать День а затем введите «дни», выберите Час а затем введите «часы», выберите Минуты а затем введите «минуты» и выберите Второй и введите «секунды»

  1. Щелкните Применить.

Вы поможете развитию сайта, поделившись страницей с друзьями

This wikiHow teaches you how to convert seconds to minutes in Microsoft Excel. After running a formula that tells Excel to interpret the seconds as time, you can display the results in a proper time format.

Steps

  1. Image titled Convert Seconds to Minutes in Excel Step 1

    1

    Open your spreadsheet in Microsoft Excel. You’ll usually find Excel in the All Apps area of the Start menu (Windows) or in the Applications folder (macOS).

  2. Image titled Convert Seconds to Minutes in Excel Step 2

    2

    Click an empty cell and type =. Use a cell in an empty column. This creates a new formula.

  3. Image titled Convert Seconds to Minutes in Excel Step 3

    3

    Click the cell that contains the seconds you want to convert. The cell’s location (e.g., B4) now appears in the formula.

  4. Image titled Convert Seconds to Minutes in Excel Step 4

    4

    Type /86400. This tells Excel to divide the number of seconds by 86400.

    • 86400 is 24 (hours in a day) X 60 (minutes in an hour) X 60 (seconds in a minute).[1]
    • The formula should now look like this (using ″B4″ as the cell containing the number of seconds): =B4/86400.
    • To simply convert a value in seconds to a value in minutes, you can divide by 60 instead. To format the value as a time, though, use the 86,400 value and continue on to the next step.
  5. Image titled Convert Seconds to Minutes in Excel Step 5

    5

    Press Enter or Return. The results of the formula will appear. The format may still appear funny, but you’re about to fix that.

  6. Image titled Convert Seconds to Minutes in Excel Step 6

    6

    Right-click the letter above the column in which you entered the formula. For example, if you typed the formula in C4, right-click the C above the column. This selects the column and opens a menu.

  7. Image titled Convert Seconds to Minutes in Excel Step 7

    7

    Click Number Format. If you don’t see this option, click Format then «»Cells»» or «»Format cells»», and then click the Number tab.[2]

  8. Image titled Convert Seconds to Minutes in Excel Step 8

    8

    Click Time. It’s under the ″Category″ header on the left side of the panel. A list of time formats will appear.

  9. Image titled Convert Seconds to Minutes in Excel Step 9

    9

    Select a time format. Since you’re working with seconds, choose either 30.55.2 (popular in most countries) or 37:30:55 (popular in the US), as these formats display hours, minutes, and seconds.

  10. Image titled Convert Seconds to Minutes in Excel Step 10

    10

    Click OK. The seconds you converted to minutes now appear in the correct format.

Ask a Question

200 characters left

Include your email address to get a message when this question is answered.

Submit

References

About this article

Article SummaryX

1. Open an Excel spreadsheet.
2. Select the cells you want to convert.
3. Right-click on the selected cells, and click Format Cells.
4. Select Custom under Category.
5. Select «mm:ss» under Type.

Did this summary help you?

Thanks to all authors for creating a page that has been read 2,483 times.

Is this article up to date?

Понравилась статья? Поделить с друзьями:
  • Excel time code to date
  • Excel time between dates
  • Excel this row number
  • Excel this row in formula
  • Excel this cell row