Skip to main content

Date to Julian Day Converter

Convert between calendar dates and Julian Day Numbers used in astronomy and programming. Enter values for instant results with step-by-step formulas.

Skip to calculator
Date & Time

Date to Julian Day Converter

Convert between calendar dates and Julian Day Numbers used in astronomy, satellite tracking, and programming. Supports JD, MJD, and TJD formats.

Last updated: December 2025

Calculator

Adjust values & calculate
Julian Day (JD)
2460311.000000
Julian Day Number
2460311
Modified JD (MJD)
60310.500000
Truncated JD (TJD)
20310.500000

Additional Details

Input Date2024-01-01 12:00 UT
Day of Year1
Day of WeekMonday
Unix Timestamp1704110400
Your Result
JD = 2460311.000000 | JDN = 2460311 | MJD = 60310.500000
Share Your Result
Understand the Math

Formula

JDN = day + โŒŠ(153m+2)/5โŒ‹ + 365y + โŒŠy/4โŒ‹ - โŒŠy/100โŒ‹ + โŒŠy/400โŒ‹ - 32045

The Julian Day Number is computed from the Gregorian calendar date by adjusting January and February as months 13-14 of the prior year, then applying the formula that accounts for leap years. The full Julian Day adds the time fraction (hour-12)/24.

Last reviewed: December 2025

Worked Examples

Example 1: Moon Landing Date to Julian Day

Convert the Apollo 11 Moon landing date, July 20, 1969, at 20:17 UT, to Julian Day.
Solution:
Year = 1969, Month = 7, Day = 20, Hour = 20, Minute = 17 a = floor((14-7)/12) = 0 y = 1969 + 4800 - 0 = 6769 m = 7 + 0 - 3 = 4 JDN = 20 + floor((153*4+2)/5) + 365*6769 + floor(6769/4) - floor(6769/100) + floor(6769/400) - 32045 JDN = 2440423 JD = 2440423 + (20-12)/24 + 17/1440 = 2440423.345
Result: JD = 2440423.345 | MJD = 40422.845 | Day of week: Sunday

Example 2: Julian Day to Calendar Date

Convert Julian Day 2451545.0 (the J2000.0 standard epoch) back to a calendar date.
Solution:
JD = 2451545.0 z = floor(2451545.0 + 0.5) = 2451545 alpha = floor((2451545 - 1867216.25)/36524.25) = 16 a = 2451545 + 1 + 16 - 4 = 2451558 b = 2451558 + 1524 = 2453082 c = floor((2453082-122.1)/365.25) = 6715 dd = floor(365.25*6715) = 2452888 e = floor((2453082-2452888)/30.6001) = 6 Day = 2453082 - 2452888 - floor(30.6001*6) = 11 โ†’ adjusted = 1 Month = 6-1 = 5 โ†’ adjusted = 1 Year = 6715-4716 = 1999 โ†’ adjusted = 2000
Result: January 1, 2000 at 12:00 UT (noon) โ€” the J2000.0 epoch
Expert Insights

Background & Theory

The Date to Julian Day Converter applies the following established principles and formulas. Date and time calculations underpin a vast range of applications from financial settlement to scheduling and age verification. The complexity arises because civil timekeeping uses irregular units: months have 28, 29, 30, or 31 days; years have 365 or 366 days; hours, minutes, and seconds use base-60 arithmetic; and time zones introduce offsets ranging from -12:00 to +14:00 relative to UTC. The Gregorian calendar's leap year rule is a compound condition: a year is a leap year if it is divisible by 4, except for century years, which must be divisible by 400. Thus 1900 was not a leap year but 2000 was. This rule keeps the calendar synchronized with the solar year to within about 26 seconds per year. For algorithmic date calculations, the Julian Day Number provides a continuous integer count of days since January 1, 4713 BCE, eliminating the irregularity of calendar months and making interval arithmetic straightforward. The Unix epoch, by contrast, counts seconds since 00:00:00 UTC on January 1, 1970, and is the basis of POSIX time used in most computing systems. ISO 8601 standardizes date and time representation as YYYY-MM-DD and combined datetime as YYYY-MM-DDTHH:MM:SSยฑHH:MM, ensuring unambiguous machine-readable interchange across locales that would otherwise differ in day/month/year ordering. Business day calculation requires excluding weekends and, optionally, a jurisdiction-specific list of public holidays. Duration calculations expressed in years, months, and days must account for the variable length of months, making them non-commutative: the interval from January 31 to February 28 is different from the interval from February 28 to March 31. Age calculation algorithms must handle the edge case of birthdays on February 29 and ensure that a person born on December 31 is not counted as one year older on January 1 of the following year until the clock passes midnight. Zeller's Congruence provides a closed-form formula to determine the day of the week for any Gregorian or Julian calendar date using only integer arithmetic.

History

The history behind the Date to Julian Day Converter traces back through the following developments. The need to track time and predict astronomical events gave rise to calendrical systems independently across many civilizations. The Babylonians, around 2000 BCE, developed a lunisolar calendar with 12 months of alternating 29 and 30 days, inserting an intercalary month periodically to keep pace with the solar year. They also divided the day into 24 hours and the hour into 60 minutes, a sexagesimal convention that persists in every modern clock. The Egyptian civil calendar used 12 months of exactly 30 days plus five epagomenal days, totaling 365 days. Though simple for administrative purposes, it drifted against the solar year by one day every four years. Julius Caesar, advised by the Egyptian astronomer Sosigenes, reformed the Roman calendar in 45 BCE. The Julian calendar introduced a 365-day year with a leap day every four years, a system that served Europe for over sixteen centuries. By the 16th century, the accumulated error of the Julian calendar had shifted the spring equinox ten days from its ecclesiastically mandated date, disrupting the calculation of Easter. Pope Gregory XIII commissioned the calendar reform that bears his name, and the Gregorian calendar was introduced in Catholic countries in October 1582. The transition required skipping ten days: October 4 was followed by October 15. Protestant and Orthodox countries adopted the reform slowly; Britain and its colonies switched in 1752, Russia not until 1918, and Greece in 1923. The expansion of railways in the 1840s created an urgent practical problem: each city operated on its own local solar time, making train timetables impossible to coordinate. British railways adopted Greenwich Mean Time as a standard in 1847. The International Meridian Conference of 1884 in Washington formalized the prime meridian at Greenwich and established the global framework of 24 time zones. Daylight saving time was first adopted nationally during World War I to reduce coal consumption. The development of atomic clocks after World War II led to the definition of Coordinated Universal Time (UTC) in 1960, accurate to nanoseconds. The Y2K problem of 1999-2000 demonstrated that two-digit year storage in legacy systems could cause widespread failures, prompting a global remediation effort costing an estimated 300 to 600 billion dollars.

Share this calculator

Explore More

Frequently Asked Questions

The Julian Day Number is a continuous count of days that has been running since the beginning of the Julian Period on January 1, 4713 BC in the proleptic Julian calendar (November 24, 4714 BC in the Gregorian calendar). It was devised by Joseph Justus Scaliger in 1583 and named after his father Julius Caesar Scaliger, not after the Julian calendar. Astronomers use JDN because it provides a single continuous number for any date, eliminating complications from varying month lengths, leap years, and calendar reforms. The Julian Day starts at noon Universal Time, so JD 2451545.0 corresponds to January 1, 2000, at 12:00 UT (noon).
Astronomers use Julian Days because they provide a uniform, continuous timescale that avoids all the complications of civil calendars. Regular calendars have variable month lengths (28-31 days), leap years, different calendar systems (Julian vs. Gregorian), and historical inconsistencies like the missing days when the Gregorian calendar was adopted in 1582. Calculating the number of days between two historical dates using regular calendars requires handling all these edge cases. With Julian Days, finding the interval between any two dates is simply a subtraction. Julian Days are also essential for astronomical ephemerides, satellite tracking, and coordinating observations across different time zones and locations worldwide.
The conversion from a Gregorian calendar date to Julian Day Number uses an algorithm that accounts for the varying month lengths and leap year rules. The standard formula involves adjusting the year and month so that January and February are treated as months 13 and 14 of the previous year. The core formula is: JDN = day + floor((153*m+2)/5) + 365*y + floor(y/4) - floor(y/100) + floor(y/400) - 32045, where y and m are the adjusted year and month. To get the full Julian Day with time, add (hour-12)/24 + minute/1440 + second/86400. The subtraction of 12 hours accounts for the Julian Day starting at noon rather than midnight.
In programming, Julian Day Numbers serve several practical purposes. Database systems like SQLite and Oracle use Julian Days internally for date arithmetic because simple subtraction gives the exact number of days between dates. Many satellite tracking systems (TLE format) use Julian dates for orbital element epochs. Financial applications use Julian dates for calculating day-count fractions in bond pricing. Scientific data logging often stores timestamps as Julian Days for precision and unambiguity. The Unix timestamp (seconds since January 1, 1970) can be converted to JD by the formula: JD = unix_seconds/86400 + 2440587.5. Julian Days are also used in GPS systems, where the GPS epoch (January 6, 1980) corresponds to JD 2444244.5.
You may use the results for reference and educational purposes. For professional reports, academic papers, or critical decisions, we recommend verifying outputs against peer-reviewed sources or consulting a qualified expert in the relevant field.
All calculations use established mathematical formulas and are performed with high-precision arithmetic. Results are accurate to the precision shown. For critical decisions in finance, medicine, or engineering, always verify results with a qualified professional.
Educational Note: This calculator is provided for educational and informational purposes. Results are based on the formulas and inputs provided. Always verify important calculations independently. NovaCalculator processes calculator inputs client-side; optional analytics follow visitor consent settings. ยฉ 2024โ€“2026 NovaCalculator.

Share this calculator

Formula

JDN = day + โŒŠ(153m+2)/5โŒ‹ + 365y + โŒŠy/4โŒ‹ - โŒŠy/100โŒ‹ + โŒŠy/400โŒ‹ - 32045

The Julian Day Number is computed from the Gregorian calendar date by adjusting January and February as months 13-14 of the prior year, then applying the formula that accounts for leap years. The full Julian Day adds the time fraction (hour-12)/24.

Worked Examples

Example 1: Moon Landing Date to Julian Day

Problem: Convert the Apollo 11 Moon landing date, July 20, 1969, at 20:17 UT, to Julian Day.

Solution: Year = 1969, Month = 7, Day = 20, Hour = 20, Minute = 17\na = floor((14-7)/12) = 0\ny = 1969 + 4800 - 0 = 6769\nm = 7 + 0 - 3 = 4\nJDN = 20 + floor((153*4+2)/5) + 365*6769 + floor(6769/4) - floor(6769/100) + floor(6769/400) - 32045\nJDN = 2440423\nJD = 2440423 + (20-12)/24 + 17/1440 = 2440423.345

Result: JD = 2440423.345 | MJD = 40422.845 | Day of week: Sunday

Example 2: Julian Day to Calendar Date

Problem: Convert Julian Day 2451545.0 (the J2000.0 standard epoch) back to a calendar date.

Solution: JD = 2451545.0\nz = floor(2451545.0 + 0.5) = 2451545\nalpha = floor((2451545 - 1867216.25)/36524.25) = 16\na = 2451545 + 1 + 16 - 4 = 2451558\nb = 2451558 + 1524 = 2453082\nc = floor((2453082-122.1)/365.25) = 6715\ndd = floor(365.25*6715) = 2452888\ne = floor((2453082-2452888)/30.6001) = 6\nDay = 2453082 - 2452888 - floor(30.6001*6) = 11 โ†’ adjusted = 1\nMonth = 6-1 = 5 โ†’ adjusted = 1\nYear = 6715-4716 = 1999 โ†’ adjusted = 2000

Result: January 1, 2000 at 12:00 UT (noon) โ€” the J2000.0 epoch

Frequently Asked Questions

What is a Julian Day Number (JDN)?

The Julian Day Number is a continuous count of days that has been running since the beginning of the Julian Period on January 1, 4713 BC in the proleptic Julian calendar (November 24, 4714 BC in the Gregorian calendar). It was devised by Joseph Justus Scaliger in 1583 and named after his father Julius Caesar Scaliger, not after the Julian calendar. Astronomers use JDN because it provides a single continuous number for any date, eliminating complications from varying month lengths, leap years, and calendar reforms. The Julian Day starts at noon Universal Time, so JD 2451545.0 corresponds to January 1, 2000, at 12:00 UT (noon).

Why do astronomers use Julian Days instead of regular dates?

Astronomers use Julian Days because they provide a uniform, continuous timescale that avoids all the complications of civil calendars. Regular calendars have variable month lengths (28-31 days), leap years, different calendar systems (Julian vs. Gregorian), and historical inconsistencies like the missing days when the Gregorian calendar was adopted in 1582. Calculating the number of days between two historical dates using regular calendars requires handling all these edge cases. With Julian Days, finding the interval between any two dates is simply a subtraction. Julian Days are also essential for astronomical ephemerides, satellite tracking, and coordinating observations across different time zones and locations worldwide.

How is the Julian Day calculated from a calendar date?

The conversion from a Gregorian calendar date to Julian Day Number uses an algorithm that accounts for the varying month lengths and leap year rules. The standard formula involves adjusting the year and month so that January and February are treated as months 13 and 14 of the previous year. The core formula is: JDN = day + floor((153*m+2)/5) + 365*y + floor(y/4) - floor(y/100) + floor(y/400) - 32045, where y and m are the adjusted year and month. To get the full Julian Day with time, add (hour-12)/24 + minute/1440 + second/86400. The subtraction of 12 hours accounts for the Julian Day starting at noon rather than midnight.

What are common uses of Julian Day Numbers in programming?

In programming, Julian Day Numbers serve several practical purposes. Database systems like SQLite and Oracle use Julian Days internally for date arithmetic because simple subtraction gives the exact number of days between dates. Many satellite tracking systems (TLE format) use Julian dates for orbital element epochs. Financial applications use Julian dates for calculating day-count fractions in bond pricing. Scientific data logging often stores timestamps as Julian Days for precision and unambiguity. The Unix timestamp (seconds since January 1, 1970) can be converted to JD by the formula: JD = unix_seconds/86400 + 2440587.5. Julian Days are also used in GPS systems, where the GPS epoch (January 6, 1980) corresponds to JD 2444244.5.

How do I get the most accurate result?

Enter values as precisely as possible using the correct units for each field. Check that you have selected the right unit (e.g. kilograms vs pounds, meters vs feet) before calculating. Rounding inputs early can reduce output precision.

What inputs do I need to use Date to Julian Day Converter accurately?

Each field is labelled with the required unit (metric or imperial). Gather your source values before starting โ€” for example, a weight measurement in kilograms, a distance in metres, or a dollar amount โ€” and enter them exactly as measured. The formula section on this page lists every variable and explains what each represents.

References

Reviewed by Abdullah, Technical Content Specialist ยท Editorial policy