You can use the following formulas in Excel to combine a date and time in separate cells into one cell in Excel:
Method 1: Use Addition
=A2+B2
Method 2: Use CONCAT and TEXT
=CONCAT(TEXT(A2,"mm/dd/yyyy")," ",TEXT(B2,"h:mm:ss AM/PM"))
The benefit of using the TEXT function is that you can specify the exact format of the resulting date and time.
Note: Both formulas assume that the date is in cell A2 and the time is in cell B2.
The following examples show how to use each method in practice with the following columns of dates and times in Excel:
Example 1: Combine Date & Time Using Addition
We can type the following formula into cell C2 to combine the date in cell A2 with the time in cell B2:
=A2+B2
We can then click and drag this formula down to each remaining cell in column C:
Column C now displays the date and time in one cell for each row.
By default, Excel does not display the AM or PM for each time and instead displays the hours on a 24-hour clock.
Example 2: Combine Date & Time Using CONCAT and TEXT
We can type the following formula into cell C2 to combine the date in cell A2 with the time in cell B2:
=CONCAT(TEXT(A2,"mm/dd/yyyy")," ",TEXT(B2,"h:mm:ss AM/PM"))
We can then click and drag this formula down to each remaining cell in column C:
Column C now displays the date and time in one cell for each row.
Note that we specified mm/dd/yyyy as the format for the date and h:mm:ss AM/PM as the format for the time.
We could also use the TEXT function to specify a different format for the resulting date and time.
For example, we could instead type the following formula into cell C2:
=CONCAT(TEXT(A2,"dd-mm-yyyy")," ",TEXT(B2,"h:mm AM/PM"))
We can then click and drag this formula down to each remaining cell in column C:
Column C now displays the date with the day first, then the month, then the year with dashes in between.
The time is also displayed using only hours and minutes.
Feel free to use whichever formats you’d like within the TEXT functions in the formula to format the resulting date and time in any way you want.
Additional Resources
The following tutorials explain how to perform other common operations in Excel:
Excel: Calculate Difference Between Two Times in Hours
Excel: Calculate Difference Between Two Times in Minutes
Excel: How to Calculate Average Time