Adding an hour in excel

Add time

Suppose that you want to know how many hours and minutes it will take to complete two tasks. You estimate that the first task will take 6 hours and 45 minutes and the second task will take 9 hours and 30 minutes.

Here is one way to set this up in the a worksheet.

  1. Enter 6:45 in cell B2, and enter 9:30 in cell B3.

  2. In cell B4, enter =B2+B3 and then press Enter.

    Time for two tasks added up

    The result is 16:15—16 hours and 15 minutes—for the completion the two tasks.

    Tip: You can also add up times by using the AutoSum function to sum numbers. Select cell B4, and then on the Home tab, choose AutoSum. The formula will look like this: =SUM(B2:B3). Press Enter to get the same result, 16 hours and 15 minutes.

Well, that was easy enough, but there’s an extra step if your hours add up to more than 24. You need to apply a special format to the formula result.

To add up more than 24 hours:

  1. In cell B2 type 12:45, and in cell B3 type 15:30.

  2. Type =B2+B3 in cell B4, and then press Enter.

    Time added up that's over 24 hours total an unexepcted result of 4:15

    The result is 4:15, which is not what you might expect. This is because the time for Task 2 is in 24-hour time. 15:30 is the same as 3:30.

  3. To display the time as more than 24 hours, select cell B4.

  4. On the Home tab, in the Cells group, choose Format, and then choose Format Cells.

    On the Home tab, Format button, and the Format cells button on the menu

  5. In the Format Cells box, choose Custom in the Category list.

  6. In the Type box, at the top of the list of formats, type [h]:mm;@ and then choose OK.

    Take note of the colon after [h] and a semicolon after mm.

The result is 28 hours and 15 minutes. The format will be in the Type list the next time you need it.

Subtract time

Here’s another example: Let’s say that you and your friends know both your start and end times at a volunteer project, and want to know how much time you spent in total.

Follow these steps to get the elapsed time—which is the difference between two times.

  1. In cell B2, enter the start time and include “a” for AM or “p” for PM. Then press Enter.

  2. In cell C2, enter the end time, including “a” or “p” as appropriate, and then press Enter.

  3. Type the other start and end times for your friends, Joy and Leslie.

  4. In cell D2, subtract the end time from the start time by entering the formula =C2-B2, and then press Enter.

    One time subtracted from another to get elapsed time

  5. In the Format Cells box, click Custom in the Category list.

  6. In the Type list, click h:mm (for hours and minutes), and then click OK.

    Now we see that Richard worked 3 hours and 45 minutes.

    Elpased times listed in column D

  7. To get the results for Joy and Leslie, copy the formula by selecting cell D2 and dragging to cell D4.

    The formatting in cell D2 is copied along with the formula.

To subtract time that’s more than 24 hours:

It is necessary to create a formula to subtract the difference between two times that total more than 24 hours.

Follow the steps below:

  1. Referring to the above example, select cell B1 and drag to cell B2 so that you can apply the format to both cells at the same time.

  2. In the Format Cells box, click Custom in the Category list.

  3. In the Type box, at the top of the list of formats, type m/d/yyyy h:mm AM/PM.

    Notice the empty space at the end of yyyy and at the end of mm.

    The new format will be available when you need it in the Type list.

  4. In cell B1, type the start date, including month/day/year and time using either “a” or “p” for AM and PM.

    Elapsed time over 24 hours

  5. In cell B2, do the same for the end date.

  6. In cell B3, type the formula =(B2-B1)*24.

The result is 31.5 hours.

Note: You can add and subtract more than 24 hours in Excel for the web but you cannot apply a custom number format.

Add time

Suppose you want to know how many hours and minutes it will take to complete two tasks. You estimate that the first task will take 6 hours and 45 minutes and the second task will take 9 hours and 30 minutes.

  1. In cell B2 type 6:45, and in cell B3 type 9:30.

  2. Type =B2+B3 in cell B4, and then press Enter.

Time for two tasks added up

It will take 16 hours and 15 minutes to complete the two tasks.

Tip: You can also add up times using AutoSum. Click in cell B4. Then click Home > AutoSum. The formula will look like this: =SUM(B2:B3). Press Enter to get the result, 16 hours and 15 minutes.

Subtract time

Say you and your friends know your start and end times at a volunteer project, and want to know how much time you spent. In other words, you want the elapsed time or the difference between two times.

  1. In cell B2 type the start time, enter a space, and then type “a” for AM or “p” for PM, and press Enter. In cell C2, type the end time, including “a” or “p” as appropriate, and press Enter. Type the other start and end times for your friends Joy and Leslie.

  2. In cell D2, subtract the end time from the start time by typing the formula: =C2-B2, and then pressing Enter. Now we see that Richard worked 3 hours and 45 minutes.

    One time subtracted from another to get elapsed time

  3. To get the results for Joy and Leslie, copy the formula by clicking in cell D2 and dragging to cell D4. The formatting in cell D2 is copied along with the formula.

    Elpased times listed in column D

I have in cel A1 with the following contents:

7:30:43
which is a time.

But now i want to use a formula to add one hour. What is the best way or how can i do this?

asked Sep 21, 2011 at 21:05

sanders's user avatar

1

=A1+TIME(1,0,0)

Although, maybe this should be posted on Super User.

apaderno's user avatar

apaderno

28.2k16 gold badges76 silver badges89 bronze badges

answered Sep 21, 2011 at 21:08

leonigmig's user avatar

leonigmigleonigmig

2,7363 gold badges25 silver badges21 bronze badges

2

In cell A1, enter the time.
In cell B2, enter =A1+1/24

Anonymous's user avatar

Anonymous

11.7k6 gold badges35 silver badges57 bronze badges

answered Mar 18, 2014 at 15:16

jenny's user avatar

jennyjenny

1411 silver badge2 bronze badges

This may help you as well. This is a conditional statement that will fill the cell with a default date if it is empty but will subtract one hour if it is a valid date/time and put it into the cell.

=IF((Sheet1!C4)="",DATE(1999,1,1),Sheet1!C4-TIME(1,0,0))

You can also substitute TIME with DATE to add or subtract a date or time.

Pᴇʜ's user avatar

Pᴇʜ

56k9 gold badges49 silver badges73 bronze badges

answered Sep 21, 2011 at 23:49

Wuggles's user avatar

Home / Excel Formulas / Add Hours into Time (Excel Formula)

To add an hour value into a time value in Excel, you can use a simple and short formula where you need to specify the original time from a cell and the hour(s) value that you want to add after dividing it by the 24 (which are totals hours that we have in a day).

In the following example, we have a time value in cell A1 (12:01 AM). And here you need to add 3 hours

cell-with-time-value

Following steps that you can use to add an hour in a time:

  1. First, refer to the cell where you have the time value (that’s A1 our example).
  2. After that, enter the sum operator and type the starting parentheses.
  3. Next, enter the hour value you want to add to the original time.
  4. Now, enter a division operator and type 24 which is the total number of hours that you have in a day.
  5. In the end, type closing parentheses and hit enter to get the result value.
formula-to-add-hours
=A1+(3/24)

The formula is quite simple. You just need to specify the original time hour value (divide it by 24).

Use Time Function to Add Time

You can also use the time function to add an hour to a time value. You can see this in the following formula.

time-function-to-add-time

You need to specify the original time, use the time function, and only specify the hour argument with the hours that you want to add.

time-function-with-hour-argument
=A1+TIME(3,0,0)

You may find that while doing payroll or working with other time-related calculations, you need to add hours to a time value in Excel.

So in this tutorial, we will go over the main ways of adding hours to time and calculating elapsed time.

In addition, we will show you how to add minutes and seconds to a time when needed.

So let’s get started.

Method #1: Add Hours to Time using the SUM Operator

The simplest way of adding, the correctly formatted hours, to a time value involves using the SUM operator.

In the example below, we have a list of times in column A and the hours we would like to add to each respective time, listed in column B.

data set where hours need to be added to time

We apply the following steps to get our desired result.

  1.  In cell C2, enter the following formula.
=A2+(B2/24)
formula to add hours to time
  1. Drag the formula down the column to see the following.
apply the formula for the entire column

Short explanation: This formula is based on the logic that a complete day is made up of 24 hours. So we have to represent the numbers in column B, as a fraction of 24. 

We are taking the initial time and adding the hours of interest.

The number representing the hours we want to add is converted to the proper time hour value by dividing it by 24.

This is then added, since hours are now in the correct format, to the start time to deliver the final result.

Note: This is a very simple method for adding hours to time, which works when we are not adding an hourly amount that is greater than 24 hours.

Method #2: Add Hours to Time using the TIME Function

The Time Function can also be used to add hours to a time.

In the following example, we have a list of times in column A and the hours we would like to add to each time, listed in column B.

data set with time and hours

We apply the following steps to get our desired result.

  1.  In cell C2, enter the following formula.
=A2+TIME(B2,0,0)
formula to add hours to time
  1. Drag the formula down the column to see the following.
apply the formula for the entire column

Short explanation: The TIME Function is used to return a decimal number that represents a certain time. Remember Excel stores dates and times as numbers.

The syntax of the TIME Function is:

=TIME(hour, minute, second).

In our formula, we take the initial time in cell A2, and then using the TIME Function we enter the hours from B2.

This is so that the value in B2 can be converted to the properly formatted decimal number. So hours will be converted to a fraction of 24.

Note: The Time Function does not allow one to add or subtract values that are greater than 23 hours, or 59 minutes, or 59 seconds. When working with these values, you have to use either the sum or subtraction operator if you have an hourly amount to be added that is greater than 24 hours.

Also read: How to Calculate Hours between two Times in Excel?

Method #3: Add over 24 Hours Time in Excel Using the Manual Method

We can use the manual method to add an hourly amount that is greater than 24 hours, cumulatively.

In our example below, we have a list of students in column A and the time they took to complete their respective tasks shown in column B.

We want to return the sum of all the hours in cell B12.

data set with time taken to complete task

We apply the following steps to get our desired result.

  1. So in cell B12, enter the following formula.
=B2+B3+B4+B5+B6+B7+B8+B9+B10+B11
simple edition arithmetic to add total time
  1. Now we have to apply the correct formatting. Right-click cell B12 and choose Format Cells…
  1.  Using the Format Cells Dialog Box, select the Custom option as the Category and type [h]:mm in the Sample section. Click Ok.
specify the time format in format cells dialog box

4) Click Ok.

total hours calculated in the right format

Method #4: Add over 24 hours in Excel Using the TEXT and SUM Function

Another way of adding amounts that exceed 24 hours is by using the TEXT Function in conjunction with the SUM Function.

We will use the same example as the one given above.

We apply the following steps to get our desired result.

  1. So this time in cell B12, enter the following formula.
=TEXT(SUM(B2:B11),"[h]:mm")
text formula to add hours

Short explanation: Remember that Excel stores TIME as a number. The TEXT Function is used to format numbers by the use of format codes. 

The syntax of the TEXT Function is:

=TEXT(value, format_text)

  • where value is the input number. In this case the number returned is from the SUM Function. 
  • format_text is the code that is used to specify the way the number is displayed which in this case is [h]:mm. This means that we display the hours and the minutes, if we specified only h then we would have seen only the hours and no minutes. 

So in summary in this formula we are adding all the hours in column B, then using the [h]:mm code, we format the hours accordingly to give us the correct result.

You will see that the value is now left-aligned since we used the TEXT Function as compared to the result obtained from our previous example.

Method #5 Calculate the Number of Hours Between Two Times Using The Subtraction Operator

A fairly common question involving time that you will come across involves how to show the difference between the two time values in hours. 

In our example below, we have a list of start times and end times for each employee.

We would like to calculate how many hours each respective employee worked.

data set with start time and end time

We apply the following steps to get our desired result.

  1. In cell D2, enter the following formula.
=C2-B2
formula to calculate number of hours worked
  1. Select cell D2 and press Ctrl 1 on your keyboard, in order to launch the Format Cells Dialog Box.
  1. Using the Format Cells Dialog Box, choose the Custom option as the Category and type h:mm as the Sample, and then click Ok.
setting the custom format for time
  1. You should see the following.
hours worked result in hours
  1. Drag the formula down the column to see the following.
drag the formula to copy it for the entire column

Note: This formula only works, when the time difference between the two given time values is not greater than 24 hours. Also, always remember when using the subtraction operator, to put the later time first.

Method #6: Adding Minutes Using the SUM operator

We can also add minutes to a time value in Excel.

In the following example, we have a list of start times in column B and the minutes we would like to add to the starting time in column C. 

data set with start time and time. in minutes

We apply the following steps to get our desired result.

  1. In cell D2, enter the following formula.
=B2+(C2/1440)
formula to get the end time
  1. Drag the formula down the column.
drag the formula for the entire column

This formula is based on the logic that we have 1440 minutes in a day. We take the original time and add the minutes of interest formatted correctly. 

The number representing the minutes we want to add, is converted to a time minute value by dividing it by 1440.

This is then added in the correct format, to the start time to deliver the end time.

Method #7: Adding Minutes to Time using the Time Function

The Time Function can also be used to add minutes to a time value.

In the following example, we have a list of start times in column B and the minutes we would like to add to each time, listed in column C.

data set with start time

We apply the following steps to get our desired result. 

1) In cell D2, enter the following formula.

=B2+TIME(0,C2,0)
formula to add minutes to start time and get the end time

2) Drag the formula down the column to see the following.

copy the formula for the entire column

Explanation of the formula: In our formula, we are taking the initial time in cell B2.

Consequently, we are using the TIME Function in cell D2 to format the numbers from C2 correctly, so that these can be converted to a decimal numbers.

Excel then adds the seconds in their correct format (which is a value divided by 1440) in order to return the result in cell D2.

Method #8: Add Seconds to Time using the TIME Function

We can use the TIME Function to add seconds to a time value. In this case we specify that the hours and minutes are 0.

In the following example, we have a list of start times in column B and the seconds we would like to add to each time, listed in column C. 

data set with start time

We apply the following steps to get our desired result.

  1. In cell D2 enter the following formula.
=B2+TIME(0,0,C2)
formula using the time function
  1. Drag the formula down the column to see the following.
copy formula for the entire column

Note: This method works when the seconds we want to add are less than 60 seconds.

Method #9: Add Hours to Time Using VBA

We have a list of student names in column A, the time they started in column B, and the hours they have taken to complete their respective task. 

We want to calculate the end time using VBA.

data set with start time and time taken in hours

We apply the following steps to get our desired result.

  1. Select range B2:B11.
select the start time data range
  1. Go to the Developer Tab and in the Code Group and the click on the Visual Basic option.
click on the visual basic icon in the ribbon
  1. Go to Insert and select Module.
insert a module
  1. Copy and paste the following code into the module code window.
'Code developed by Steve Scott from https://spreadsheetplanet.com
Sub Adding_Hours_To_Time()
Dim result1 As Variant
For Each cell In Selection
result1 = CDate(cell + (cell.Offset(0, 1) / 24))
cell.Offset(0, 2).Value = result1
Next
End Sub
  1. Press F5 to run the code. You should see the following.
run the code to get the end time

In the above code, we have used the For Each statement to go through each cell in the selection, and then get the result In column D (which is two columns to the right)

So as soon as you run the code, it is going to add the number of hours in column C to the start time in column B and give us the result in column D

In this article, we went through simple ways to add hours to time in Excel, which will help you when doing time tracking and other time-related calculations. 

We also covered the simple ways of adding minutes and seconds to a time value in Excel.

Other Excel articles you may also like:

  • How to Round Time to the Nearest Quarter Hour in Excel?
  • How to Insert Date in Excel? (Shortcut + Formulas)
  • How to Separate Date and Time in Excel
  • How To Combine Date and Time in Excel
  • How to Change Date and Time to Date in Excel
  • How to Convert Days to Years in Excel (Simple Formulas)

Return to Excel Formulas List

Download Example Workbook

Download the example workbook

This tutorial will demonstrate how to add hours to a time in Excel and Google Sheets.
Add HRS Time Main

Add Hour

In Excel, time is stored as a fractional value where each 1/24th represents one hour of the day.

Time Portion

To add an hour add 1/24 to a time

=B3+(1/24)

Add Houror 12/24 to add 12 hours:

=B3+(12/24)

Add More Hours

Add Hour to Now

To add an hour to the current time, add 1/24 to the NOW Function:

=NOW()+(1/24)

Add Hour Now

Add Hours Google Sheets

All of the above examples work exactly the same in Google Sheets as in Excel.

Add HRS Time Google

Like this post? Please share to your friends:
  • Adding a line in excel
  • Adding a label in excel
  • Adding a header in word
  • Adding a glossary in word
  • Adding a formula in excel