Modified Julian Day to date converter
This Modified Julian Day to date converter turns one MJD value into a proleptic Gregorian calendar date and a UTC clock time.
Run — free
It uses only the number you supply: it does not consult the current clock, infer a timezone, contact a network service, or depend on a machine's locale. Integer MJD values identify UTC midnight, while a fractional part describes the time elapsed since that midnight. The result includes separate calendar fields plus stable date and timestamp strings for direct use in code, reports, and scientific data checks.
Enter the Modified Julian Day value you actually have
Provide the value in the mjd field as a finite decimal number. Modified Julian Day is related to the astronomical Julian Day by a fixed offset, but it has a particularly convenient civil-day boundary: an integer MJD begins at midnight UTC. For example, 51544.0 represents the start of January 1, 2000, while 51544.5 represents noon on that same date. Preserve any fractional digits from your source when the time matters. The converter accepts ordinary decimal notation and numeric scientific notation, then calculates solely from that value. It does not assume that an unlabeled number came from a local timezone, and it does not silently treat a Julian Day value as MJD. Check the label and scale in your source dataset before conversion, because confusing JD with MJD introduces an offset of millions of days rather than a small rounding discrepancy. The output repeats the accepted MJD so an automated pipeline can associate each response with its original observation. Missing, nonnumeric, infinite, and excessively large values are rejected explicitly instead of producing a plausible-looking date.
Understand the Gregorian date and UTC clock result
The response separates year, month, day, hour, minute, and second, and also supplies a date string and a complete timestamp ending in Z. That Z marks UTC; there is no local offset hidden in the calculation. The calendar is proleptic Gregorian, meaning Gregorian leap-year rules are extended backward even before the historical adoption of that calendar. This convention is deterministic and useful for computation, but a very old result may differ from the calendar label found in a historical archive that used the Julian calendar. Years use astronomical numbering, so year zero exists and corresponds to 1 BCE in historical notation. Fractional MJD values are converted to the nearest whole second. If rounding reaches the end of a day, the calculation advances to midnight of the following Gregorian day rather than returning an impossible 24:00:00 clock value. The structured fields are convenient for database columns, while the timestamp is suitable for logs and interchange. The response names both its calendar and time scale so downstream code does not have to infer either convention.
Use deterministic conversion in scientific workflows
MJD appears in astronomy tables, satellite products, observatory logs, and other datasets where a compact continuous day count is easier to compare than formatted civil timestamps. This converter is useful at the boundary where people or general-purpose systems need to read those values. A data ingestion job can convert an MJD column before indexing observations; a researcher can verify a published epoch; and a support engineer can translate a timestamp while investigating a telemetry record. Because the implementation uses integer calendar arithmetic rather than the host's date library, the same input produces the same result in a browser, an API worker, or a test runner in another timezone. That property also makes saved examples reliable regression checks. Treat UTC as the output convention, not as evidence that every source used a perfect physical realization of UTC: specialized datasets may label their day count with TT, TAI, or another time scale. If leap-second-level precision matters, confirm the source scale and apply the appropriate domain correction before interpreting the timestamp. For ordinary MJD values already specified in UTC, the returned fields are ready to store or display.
What you can do with it
Read an astronomy observation epoch
Turn an MJD value from an observation table into a recognizable Gregorian UTC timestamp for review or reporting.
Normalize scientific data imports
Convert a continuous day count into separate date and time fields before loading records into a database or search index.
Check telemetry timestamps
Translate an MJD marker from a spacecraft or instrument log while keeping the calculation independent of the analyst's timezone.
FAQ
What does one conversion cost?
Each API conversion costs $0.002 per item. The browser version can run the same deterministic calculation locally.
What is the difference between MJD and Julian Day?
Modified Julian Day equals Julian Day minus 2400000.5. The half-day shift makes integer MJD values begin at midnight UTC rather than noon.
Does the converter use my local timezone?
No. Every result is computed and labeled in UTC, regardless of the computer or browser timezone.
How are fractional days handled?
The fractional part is interpreted as elapsed time since UTC midnight and rounded to the nearest whole second.
Which calendar does the result use?
It uses the proleptic Gregorian calendar for every year, including dates before the calendar was historically introduced.
Does it account for leap seconds or convert between time scales?
No. It performs arithmetic calendar conversion on the supplied MJD and labels the result UTC; it does not convert TT, TAI, or other specialized scales.
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/date/mjd-to-date \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"mjd":51544.5}'const res = await fetch("https://api.kit.forhosting.com/date/mjd-to-date", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"mjd": 51544.5
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/date/mjd-to-date",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"mjd": 51544.5
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/date/mjd-to-date", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"mjd":51544.5}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"mjd":51544.5}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/date/mjd-to-date", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"mjd": 51544.5
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "date.mjd_to_date",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |