Astrology Calculation API for Developers
Ship birth charts, synastry, transits, aspects, and house systems in minutes — without managing ephemeris files or writing complex astronomical math.
- Birth charts, houses, aspects, synastry, and natal-to-transit aspects
- Computed directly from modern astronomical models (no scraping)
- Monthly plans with included request quotas and no automatic overages
// Node.js 22+ — run on your server, never in public browser code
fetch("https://api.astroapi.io/api/astro/birth-chart", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_KEY"
},
body: JSON.stringify({
date: "2000-01-01",
time: "12:00",
lat: 0.0,
lon: 0.0,
timezone: "UTC"
})
})
.then(res => res.json())
.then(data => console.log(data));
# Python Example
import requests
url = "https://api.astroapi.io/api/astro/birth-chart"
payload = {
"date": "2000-01-01",
"time": "12:00",
"lat": 0.0,
"lon": 0.0,
"timezone": "UTC"
}
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_API_KEY"
}
response = requests.post(url, json=payload, headers=headers)
print(response.json())
Built for Developers, Trusted by Astrology Apps
Stop fighting ephemeris math, file updates, and edge cases. AstroAPI handles the calculations so you can focus on shipping.
Targeted Astrology Endpoints
Birth charts, equal and whole-sign houses, aspects, synastry, transits, and explicit sidereal calculations.
Simple, Honest Pricing
Free tier to get started. Predictable monthly subscriptions with included request quotas and no automatic overages.
Modern Developer Experience
RESTful JSON APIs with copy-paste examples for JavaScript, Python, mobile backends, and web services.
Frequently Asked Questions
Clear answers to the questions developers actually ask.
Can I start for free?
Yes. The free tier lets you test the API without a credit card.
What features are available?
Birth charts, natal-to-transit aspects, natal aspects, synastry, equal and whole-sign houses, sidereal mode, and Pro nakshatra timelines.
Is commercial use allowed?
Yes. Paid plans include full commercial usage rights.
How do I authenticate?
Authorization: Bearer <YOUR_API_KEY>
What languages are supported?
Any language capable of sending HTTPS requests.
How accurate is the data?
Planetary positions use the bundled JPL DE421 ephemeris. House angles and lunar-node fields use documented engine approximations; see the calculation guide for scope.
Can I change plans later?
Upgrade, downgrade, or cancel anytime as your usage changes.
Is my API key secure?
API keys are returned once, stored only as one-way SHA-256 hashes, and transmitted over HTTPS. Keep them on your server.