ThisCalculator

Everyday

Convert 12 Hour to 24 Hour Time

Updated · Standard formula, shown below

The calculator for this page is switched off while it is checked. The formula is below, and the worked example in the article shows how to use it by hand.

Convert 12 Hour to 24 Hour Time

To convert a 12-hour time to 24-hour time, keep the hour the same for times from 12:00 AM to 12:59 PM, and add 12 to the hour for times from 1:00 PM to 11:59 PM. The only special cases are 12:00 AM (midnight), which becomes 00:00, and 12:00 PM (noon), which stays 12:00.

Formula

The conversion follows a simple rule based on the period (AM or PM) and the hour value. Let H be the hour on a 12-hour clock (1–12) and M be the minutes (0–59). The 24-hour hour H24 is:

  • If the period is AM and H = 12, then H24 = 0 (midnight).
  • If the period is AM and H ≠ 12, then H24 = H (e.g., 9:15 AM → 09:15).
  • If the period is PM and H = 12, then H24 = 12 (noon).
  • If the period is PM and H ≠ 12, then H24 = H + 12 (e.g., 3:30 PM → 15:30).

The result is written as HH:MM with a leading zero for hours 0–9 (e.g., 08:45). The minutes never change.

Worked Example

Using the default input 3:30 PM:

  1. Identify the period: PM.
  2. Hour = 3, which is not 12, so add 12: 3 + 12 = 15.
  3. Minutes stay 30.
  4. Write as 15:30.

So 3:30 PM converts to 15:30 in 24-hour time. The calculator above shows this result as a clock time (HH:MM).

Why Use 24-Hour Time?

The 24-hour clock, often called military time in the US, is the standard in most of the world outside North America. It removes the ambiguity of AM and PM, making schedules unambiguous. For example, 7:00 could be morning or evening, but 07:00 is always morning and 19:00 is always evening. This is especially useful in transportation timetables, hospital shifts, and international business. Many digital devices allow you to switch between 12-hour and 24-hour displays, and learning the conversion helps you read schedules when traveling.

Common Mistakes and Misconceptions

A frequent error is treating 12 AM as 12:00 instead of 00:00. Midnight is the start of the day, so 12:00 AM = 00:00. Similarly, 12 PM is noon, not midnight. Another mistake is forgetting to add 12 for PM hours when the hour is 1–11. For example, 1:00 PM becomes 13:00, not 01:00. Also, when converting from 24-hour to 12-hour, remember that hours 13–23 are PM, and you subtract 12 to get the 12-hour hour (e.g., 20:00 → 8:00 PM).

How to Convert Quickly in Your Head

Here’s a quick mental shortcut:

  • For AM times: if the hour is 12, change it to 0; otherwise keep it as is.
  • For PM times: if the hour is 12, keep it as 12; otherwise add 12 to the hour.
  • Minutes are always the same.

Practice with common times: 6:30 AM → 06:30, 12:45 PM → 12:45, 5:15 PM → 17:15, 11:59 PM → 23:59.

Where 24-Hour Time Is Used

The 24-hour clock is the official time standard in most countries, including all of Europe, Latin America, Africa, and Asia. The United States, Canada (in English-speaking regions), Australia, and New Zealand commonly use the 12-hour clock in everyday speech, but the 24-hour clock appears in military, aviation, and medical contexts. For example, airline schedules always use 24-hour time to avoid confusion across time zones. Many computer systems and programming languages use the 24-hour format as a default because it sorts and calculates more easily.

Converting Between Formats on Devices

Most smartphones and computers let you switch the clock display. On an iPhone, go to Settings → General → Date & Time → toggle “24-Hour Time.� On Android, open Settings → System → Date & time → toggle “Use 24-hour format.� In Windows, go to Settings → Time & Language → Region → Change data formats, and select a 24-hour time format. On macOS, open System Settings → General → Date & Time, and uncheck “Use 24-hour time.� These changes affect all system clocks and calendar apps.

Frequently Asked Questions

What is 12:00 AM in 24-hour time?

12:00 AM (midnight) is 00:00 in 24-hour time. It represents the start of the day. The hour after 11:59 PM is 00:00, not 12:00.

What is 12:00 PM in 24-hour time?

12:00 PM (noon) is 12:00 in 24-hour time. It is the middle of the day. The hour after 11:59 AM is 12:00 PM.

How do I convert 6:30 PM to 24-hour time?

Since 6:30 PM is PM and the hour is not 12, add 12 to 6, giving 18, and keep minutes as 30. So 6:30 PM becomes 18:30.

Why do some countries use 12-hour time?

The 12-hour clock is a historical convention, likely related to the use of analog clocks and the division of day and night into 12 hours each. It remains common in English-speaking countries, but the 24-hour clock is more prevalent globally because it reduces ambiguity.

Is there a difference between 24-hour time and military time?

In practice, they are the same format. Military time often omits the colon (e.g., 1530 instead of 15:30) and may be spoken as “fifteen thirty.� The conversion rules are identical.

What about seconds in the conversion?

Seconds are unaffected. If you have 3:30:45 PM, the 24-hour time is 15:30:45. The hour conversion applies only to the hour part.

Related

Formula used
in t | Time (12-hour) | - | 3:30 PM | 0
out h24 | Time (24-hour) | - | (hour(t) + (pm(t) && hour(t) != 12 ? 12 : 0) + (am(t) && hour(t) == 12 ? -12 : 0)) * 60 + minute(t) | clock

Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.