Get lunar phase data and images for any date
/api/v1
Returns comprehensive moon phase data for a specific date.
| Name | Type | Description |
|---|---|---|
| date | path (optional) | Date in YYYY-MM-DD format. Defaults to today. |
Example Response
{
"date": "2026-04-01",
"phase": {
"name": "Full Moon",
"age": 14.77,
"illumination": 100,
"daysSinceFull": 0,
"daysUntilFull": 30
},
"discPosition": 0.5,
"synodicPeriod": 29.53059,
"nearestFullMoon": "2026-04-01",
"upcomingFullMoons": ["2026-05-01", "2026-05-31", ...]
}
Get moon phase data for a range of dates (max 366 days).
| Name | Type | Description |
|---|---|---|
| from | string | Start date (YYYY-MM-DD) |
| to | string | End date (YYYY-MM-DD) |
Example Response
{
"from": "2026-04-01",
"to": "2026-04-07",
"count": 7,
"data": [
{ "date": "2026-04-01", "phase": { "name": "Full Moon", "age": 14.77, "illumination": 100 } },
{ "date": "2026-04-02", "phase": { "name": "Waning Gibbous", "age": 15.77, "illumination": 98 } },
...
]
}
Get all major phases (New Moon, First Quarter, Full Moon, Third Quarter) for a year.
| Name | Type | Description |
|---|---|---|
| year | number (optional) | Year (1900-2100). Defaults to current year. |
Example Response
{
"year": 2026,
"count": 49,
"phases": [
{ "date": "2026-01-03", "phase": "Full Moon" },
{ "date": "2026-01-10", "phase": "Third Quarter" },
{ "date": "2026-01-18", "phase": "New Moon" },
...
]
}
Get all full moon dates for a year.
| Name | Type | Description |
|---|---|---|
| year | number (optional) | Year (1900-2100). Defaults to current year. |
Get all new moon dates for a year.
| Name | Type | Description |
|---|---|---|
| year | number (optional) | Year (1900-2100). Defaults to current year. |
Get the next full moon date from today.
Example Response
{ "date": "2026-05-01", "daysUntil": 25 }
Get the next new moon date from today.
Example Response
{ "date": "2026-04-17", "daysUntil": 11 }
Returns a transparent PNG image of the moonphase disc.
| Name | Type | Description |
|---|---|---|
| date | path (optional) | Date in YYYY-MM-DD format. Defaults to today. |
| size | query (optional) | Width in pixels. Default: 300, Max: 1000 |
Returns an SVG image of the moonphase disc. Infinitely scalable, smaller file size.
| Name | Type | Description |
|---|---|---|
| date | path (optional) | Date in YYYY-MM-DD format. Defaults to today. |