The Horoscope API returns daily, weekly, monthly and yearly horoscopes for all 12 zodiac signs as JSON, in 25 languages. It also has a Chinese horoscope and a numerology horoscope, for apps, websites, newsletters and chatbots.
Verified live against the DivineAPI API on 2 October 2026.
Part of DivineAPI: 300+ endpoints across 8 domains, Horoscope and Tarot 40+.
1. Get your keys. Start the 14-day free trial (credit card required to activate the trial) at divineapi.com/start-trial, then copy your API key and auth token from the dashboard.
Every request is a POST with multipart/form-data, the auth token in the Authorization: Bearer header and the API key in the api_key form field.
Runnable files: examples/ (curl, Python, Node.js, PHP).
2. curl (today's horoscope for Aries)
curl -s -X POST "https://astroapi-5.divineapi.com/api/v5/daily-horoscope" \
-H "Authorization: Bearer YOUR_AUTH_TOKEN" \
-F "api_key=YOUR_API_KEY" \
-F "sign=aries" \
-F "h_day=today" \
-F "day=02" -F "month=10" -F "year=2026" \
-F "tzone=5.5"3. Python (requests)
import requests
resp = requests.post(
"https://astroapi-5.divineapi.com/api/v5/daily-horoscope",
headers={"Authorization": "Bearer YOUR_AUTH_TOKEN"},
files={ # multipart/form-data
"api_key": (None, "YOUR_API_KEY"),
"sign": (None, "aries"),
"h_day": (None, "today"),
"day": (None, "02"), "month": (None, "10"), "year": (None, "2026"),
"tzone": (None, "5.5"),
},
timeout=30,
)
body = resp.json()
if body.get("success") != 1: # astroapi-5 always answers HTTP 200
raise SystemExit(body)
data = body["data"]
print(data["sign"], data["date"])
for area in ("personal", "health", "profession", "emotions", "travel"):
print(f"{area}: {data['prediction'][area][:80]}...")
print("luck:", data["prediction"]["luck"][1])Node.js (18+, built-in fetch)
async function dailyHoroscope(sign) {
const form = new FormData();
form.append("api_key", "YOUR_API_KEY");
form.append("sign", sign);
form.append("h_day", "today");
form.append("day", "02");
form.append("month", "10");
form.append("year", "2026");
form.append("tzone", "5.5");
const res = await fetch("https://astroapi-5.divineapi.com/api/v5/daily-horoscope", {
method: "POST",
headers: { Authorization: "Bearer YOUR_AUTH_TOKEN" },
body: form,
});
const body = await res.json();
if (body.success !== 1) throw new Error(JSON.stringify(body)); // check the body, not the HTTP status
return body.data;
}
dailyHoroscope("aries").then((d) => {
console.log(d.sign, d.date);
console.log(d.prediction.personal.slice(0, 120) + "...");
console.log(d.special.horoscope_percentage);
});4. PHP (cURL)
<?php
$ch = curl_init("https://astroapi-5.divineapi.com/api/v5/daily-horoscope");
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["Authorization: Bearer YOUR_AUTH_TOKEN"],
CURLOPT_POSTFIELDS => [ // an array is sent as multipart/form-data
"api_key" => "YOUR_API_KEY",
"sign" => "aries",
"h_day" => "today",
"day" => "02", "month" => "10", "year" => "2026",
"tzone" => "5.5",
],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);
if (($body["success"] ?? 0) !== 1) { exit(print_r($body, true)); }
echo $body["data"]["sign"] . " " . $body["data"]["date"] . "\n";
echo $body["data"]["prediction"]["personal"] . "\n";Daily horoscope, live response (2 Oct 2026, trimmed). personal, health, profession, emotions and travel are strings; luck is a list of strings.
{
"success": 1,
"data": {
"sign": "Aries",
"date": "2026-10-02",
"prediction": {
"personal": "Make something before the day makes something of you, Aries. Mars occupies your zone of play, performance and creative risk, and that is where your appetite goes today...",
"health": "Mars in your creative sector runs your engine hot, and the first thing that suffers is digestion. Eat sitting down today...",
"profession": "Work today turns on who controls a budget...",
"emotions": "Your mood rides on conversation today...",
"travel": "Taste is your route today...",
"luck": [
"...",
"Lucky Numbers of the day : 3, 9, 21",
"Lucky Alphabets you will be in sync with : I, O",
"..."
]
},
"special": {
"lucky_color_codes": ["#F7CAC9", "#FFD700"],
"horoscope_percentage": {
"personal": 66,
"health": 69,
"profession": 62,
"emotions": 85,
"travel": 71,
"luck": 66
}
}
}
}Weekly, monthly and yearly use the same six areas under a different key (live responses, trimmed):
{ "success": 1, "data": { "sign": "Aries", "week": "27 Sep 2026 to 03 Oct 2026", "weekly_horoscope": { "personal": "...", "luck": ["..."] }, "special": { "...": "..." } } }
{ "success": 1, "data": { "sign": "Aries", "month": "October 2026", "monthly_horoscope": { "personal": "...", "luck": ["..."] }, "special": { "...": "..." } } }
{ "success": 1, "data": { "sign": "Aries", "year": "2026", "yearly_horoscope": { "personal": "...", "luck": ["..."] }, "special": { "...": "..." } } }Non-English horoscopes come from astroapi-5-translator.divineapi.com: same path, same fields, same auth, plus lan. The standard host answers a non-English lan with success: 2 and points you to the translator. Translated replies can take 25 to 35 seconds, so allow a 60-second timeout.
curl -s --max-time 60 -X POST "https://astroapi-5-translator.divineapi.com/api/v5/daily-horoscope" \
-H "Authorization: Bearer YOUR_AUTH_TOKEN" \
-F "api_key=YOUR_API_KEY" \
-F "sign=aries" -F "h_day=today" \
-F "day=02" -F "month=10" -F "year=2026" \
-F "tzone=5.5" \
-F "lan=es"Live response in Spanish (trimmed):
{
"success": 1,
"data": {
"sign": "Aries",
"date": "2026-10-02",
"prediction": {
"personal": "Haz algo antes de que el día haga algo de ti, Aries. Marte ocupa tu zona de juego, rendimiento y riesgo creativo, y ahí va tu apetito hoy...",
"health": "Marte en tu sector creativo acelera tu motor, y lo primero que sufre es la digestión...",
"...": "..."
}
}
}The same call in Hindi from Python:
import requests
resp = requests.post(
"https://astroapi-5-translator.divineapi.com/api/v5/daily-horoscope",
headers={"Authorization": "Bearer YOUR_AUTH_TOKEN"},
files={
"api_key": (None, "YOUR_API_KEY"),
"sign": (None, "aries"),
"h_day": (None, "today"),
"day": (None, "02"), "month": (None, "10"), "year": (None, "2026"),
"tzone": (None, "5.5"),
"lan": (None, "hi"),
},
timeout=60, # the translator can take 25-35 s
)
data = resp.json()["data"]
print(data["sign"], data["date"]) # मेष 2026-10-02
print(data["prediction"]["health"][:60])What the standard host says if you send lan=hi to it (live):
{
"success": 2,
"msg": [
"Translation is not supported on this domain. Please use https://astroapi-5-translator.divineapi.com/api/v5/daily-horoscope for translated (non-English) responses."
]
}DivineAPI uses its own language codes, not ISO 639-1. Note Marathi ma, Tamil tm, Telugu tl, Greek gr, Filipino ta, Indonesian bah.
| Code | Language | Code | Language | Code | Language |
|---|---|---|---|---|---|
en |
English | it |
Italian | ma |
Marathi |
hi |
Hindi | nl |
Dutch | tm |
Tamil |
zh |
Chinese | pl |
Polish | tl |
Telugu |
ja |
Japanese | tr |
Turkish | ml |
Malayalam |
ar |
Arabic | uk |
Ukrainian | kn |
Kannada |
ru |
Russian | hu |
Hungarian | ta |
Filipino |
pt |
Portuguese | gr |
Greek | bah |
Indonesian |
es |
Spanish | bn |
Bengali | ||
fr |
French | de |
German |
- A "today for your sign" card on a homepage or app home screen, refreshed once a day per sign.
- A weekly horoscope email that pulls
week=currentfor all 12 signs on Sunday night. - A localised horoscope section in Hindi, Spanish, Arabic or any of the 25 languages from one integration.
- A Chinese zodiac page (Rat to Pig) next to the Western signs.
- A daily numerology horoscope for users who know their number.
All on astroapi-5.divineapi.com (English) or astroapi-5-translator.divineapi.com (25 languages). Paths are from the OpenAPI spec.
| Endpoint | Path | Period selector | Docs |
|---|---|---|---|
| Daily horoscope | /api/v5/daily-horoscope |
h_day = today / tomorrow / yesterday (+ day, month, year) |
docs |
| Weekly horoscope | /api/v5/weekly-horoscope |
week = current / prev / next |
docs |
| Monthly horoscope | /api/v5/monthly-horoscope |
month = current / prev / next |
docs |
| Yearly horoscope | /api/v5/yearly-horoscope |
year = current / prev / next |
docs |
| Chinese horoscope | /api/v3/chinese-horoscope |
sign = animal (e.g. tiger), h_day = today |
docs |
| Numerology horoscope | /api/v2/numerology-horoscope |
number + day, month, year (yesterday, today or tomorrow only) |
docs |
Every endpoint also takes api_key, tzone and optional lan.
Chinese horoscope, live response (sign=tiger, h_day=today, trimmed):
{
"success": 1,
"data": {
"sign": "Tiger",
"date": "02 Oct 2026",
"prediction": {
"growth": "Today, the Xin Metal influence encourages introspection and fine-tuning of inner energies...",
"health": "...", "wealth": "...", "career": "...", "love": "...", "family": "...",
"fortune": ["Lucky Numbers of the day : 5,17,23", "..."]
}
}
}Numerology horoscope, live response (number=1, trimmed):
{
"success": 1,
"data": {
"number": 1,
"prediction": {
"result": "Today’s Universal Day Number 4 brings a grounding energy that complements your natural ambition and leadership as a Life Path Number 1..."
}
}
}Tarot and love readings live in tarot-api.
| Field | Format | Note |
|---|---|---|
sign |
lowercase zodiac name: aries ... pisces |
Chinese horoscope takes an animal name instead. |
h_day / week / month / year |
keyword selector | Never a calendar date: today, tomorrow, yesterday; current, prev, next. |
tzone |
decimal hours, e.g. 5.5, -5 |
Decides which "today" the user gets. Never +5:30 or a zone name. |
lan |
DivineAPI language code, default en |
Non-English only on the translator host. |
number |
a number, e.g. 1 |
Numerology horoscope only. |
- Check
success, not the HTTP status. astroapi-5 always answers HTTP 200:success: 1ok,2validation error,3auth error (readmsg). Do not retry on3; fix the key or token. - Numerology horoscope serves only yesterday, today and tomorrow; other dates return
success: 2. - Timeouts: allow 60 seconds on the translator host.
- Caching: a daily horoscope for one sign, day,
tzoneandlancan be cached until the next day in that zone.
pip install divineapi
npm install divineapi
composer require divineapi/divineapi
The examples above use plain HTTP so they work in any language. SDK repos: divineapi-python, divineapi-node, divineapi-php.
MCP server (Horoscope, Tarot and Numerology) for Claude, Cursor, VS Code and other MCP clients:
https://mcp.divineapi.com/horoscope/mcp
Setup steps: mcp-horoscope-numerology.
Horoscope endpoints are sold in two Horoscope plans, Horoscope Starter and Horoscope Pro. The pricing page lists what each one includes: divineapi.com/pricing.
How do I ask for tomorrow's horoscope or next week's?
Use the keyword selectors: h_day=tomorrow on the daily endpoint, week=next on weekly, month=next on monthly, year=next on yearly. Calendar dates are not accepted as selectors.
Why do I get "Translation is not supported on this domain"?
You sent a non-English lan to astroapi-5. Send the same request to astroapi-5-translator.divineapi.com.
Which language code is Tamil?
tm. DivineAPI's codes differ from ISO: Marathi ma, Tamil tm, Telugu tl, Greek gr, Filipino ta, Indonesian bah.
Do I get an HTTP error when my key is wrong?
No. astroapi-5 returns HTTP 200 with success: 3 and a msg. Always read success.
Is the numerology horoscope the same as the Numerology API? No. The numerology horoscope is a daily horoscope feed (25 languages through the translator). Core numbers and numerology reports are in numerology-api, English only.
Can I try the horoscope feed before choosing a plan? Yes. The 14-day free trial (credit card required to activate the trial) gives you a key and token for the daily, weekly, monthly and yearly calls above. Horoscope Starter and Horoscope Pro prices are on divineapi.com/pricing.
| Repo | What it covers |
|---|---|
| astrology-api | Overview of all DivineAPI products |
| tarot-api | Tarot and love readings with card images, 25 languages |
| birth-chart-api | Western natal chart: planets, houses, aspects, wheel |
| kundli-api | Vedic birth chart (kundli) |
| panchang-api | Panchang, muhurat, choghadiya |
| numerology-api | Numerology numbers and reports |
| hindu-festival-api | Hindu festival dates |
| mcp-horoscope-numerology | MCP server for horoscope, tarot and numerology |
- Docs: developers.divineapi.com
- Postman collection: documenter.getpostman.com/view/26759678/2sBYAysU8Y
- Help centre: support.divineapi.com
- API status: status.divineapi.com
- Product page: divineapi.com/horoscope/horoscope-api
DivineAPI was founded in 2021 in New Delhi, India, and serves 600+ businesses.
Code samples in this repository are released under the MIT License (see LICENSE). The DivineAPI name and logo are trademarks of DivineAPI.
