24 Hour to 12 Hour Time Conversion
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.
This calculator converts a 24-hour time (e.g., 14:30) into the equivalent 12-hour clock time with AM/PM (e.g., 2:30 PM). You enter the hour and minute as they appear on a 24-hour clock, and the result shows the same moment expressed on a 12-hour clock, including the correct AM or PM suffix.
Formula
The conversion uses two simple rules:
- Hour:
((h + 11) % 12) + 1, wherehis the hour from the 24-hour clock (0–23). The%symbol is the modulo operation (remainder after division). - Suffix: If
his less than 12, the time is AM; otherwise it is PM.
For the minute part, you simply carry it over unchanged – minutes are the same on both clocks. The formula converts the hour only; the minute value stays as entered.
Worked Example
Using the default values from the calculator above (hour = 14, minute = 30):
- Apply the hour formula:
((14 + 11) % 12) + 1=(25 % 12) + 1=1 + 1= 2. - Check the suffix: 14 is not less than 12, so the suffix is PM.
- Keep the minute: 30 stays as 30.
- Result: 2:30 PM.
This matches what the calculator outputs for the default inputs.
Why We Use Two Clocks
The 24-hour clock (often called military time in the US) numbers the hours from 0 to 23, where 0:00 is midnight and 12:00 is noon. The 12-hour clock splits the day into two 12-hour blocks: AM (ante meridiem, Latin for “before midday�) and PM (post meridiem, “after midday�). Most of the world uses the 24-hour clock for official schedules – train timetables, airline departures, hospital shifts, and military operations – while the 12-hour clock is common in everyday conversation in countries like the US, Canada, and Australia. Understanding both is essential for reading international schedules or converting times when traveling.
How to Convert Manually
You don’t always need a calculator. Here’s the step-by-step process:
- If the hour is 0, it becomes 12 AM (midnight).
- If the hour is from 1 to 11, keep the same number and add AM.
- If the hour is 12, keep 12 and add PM (noon).
- If the hour is from 13 to 23, subtract 12 and add PM.
For example, 09:45 becomes 9:45 AM, 12:00 becomes 12:00 PM, and 21:15 becomes 9:15 PM. The minutes never change.
Common Mistakes and Confusions
One common error is treating 12:00 as 0:00. On a 12-hour clock, 12:00 AM is midnight and 12:00 PM is noon – there is no 0:00 on a 12-hour display. Another frequent mix-up is forgetting that 12:00 PM is noon, not midnight. When converting 12:00 from 24-hour time, it stays 12:00 PM. Also, be careful with times like 00:30 – that’s 12:30 AM, not 12:30 PM. The formula above handles all these cases correctly because it treats 0 and 12 specially.
Practical Uses for the Conversion
You’ll need this conversion in many everyday situations:
- Reading train or bus schedules in Europe, where 24-hour times are standard.
- Converting a flight departure time from a boarding pass that uses 24-hour format.
- Setting an alarm clock that only shows 12-hour time.
- Understanding military or medical shift times, which are often written as 24-hour.
- Converting times in digital documents or spreadsheets that use the 24-hour clock.
When you travel, it’s helpful to remember that 18:00 is 6:00 PM, and 20:00 is 8:00 PM – a simple subtraction of 12 for hours after noon.
Frequently Asked Questions
Is 24:00 a valid time?
Sometimes, especially in scheduling, 24:00 is used to mean midnight at the end of a day. However, in standard 24-hour time, midnight is 00:00. The calculator treats 24:00 as invalid because the hour input is limited to 0–23. If you see 24:00, it’s equivalent to 00:00 the next day.
How do I convert 00:00 to 12-hour time?
00:00 is midnight, and on a 12-hour clock it is 12:00 AM. The formula gives ((0 + 11) % 12) + 1 = (11 % 12) + 1 = 11 + 1 = 12, and since 0 is less than 12, the suffix is AM.
What is the difference between 12 AM and 12 PM?
12 AM is midnight (the start of the day), and 12 PM is noon (the middle of the day). This is a common point of confusion because neither is “ante� or “post� meridiem in the usual sense – noon is exactly at the meridian, and midnight is 12 hours before or after it. The convention is that 12:00 AM is the start of the day, and 12:00 PM is the middle.
Does the minute ever change during conversion?
No. The minute value is identical in both 24-hour and 12-hour clocks. Only the hour representation changes. For example, 15:45 is 3:45 PM – the 45 minutes stay the same.
Why do some countries use 24-hour time and others use 12-hour?
There’s no single reason; it’s a mix of historical convention and standardization. The 24-hour clock is widely used in Europe, Latin America, and the military, while the 12-hour clock is common in North America, Australia, and some other English-speaking countries. Many digital devices now let you choose your preferred format, so people often become familiar with both.
Related
Formula used
in h | Hour (0-23) | h | 14 | 0 in min | Minute (0-59) | min | 30 | 0 out t12 | 12-hour time | - | ((h + 11) % 12) + 1 | 0 out suffix | AM/PM | - | (h < 12 ? "AM" : "PM") | 0
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.