Suncalc
Suncalc: Open-Source JavaScript Library
Calculate sun position, sunlight phases, moon position, and lunar phase for a given location and time with this lightweight, dependency-free JavaScript library
What is Suncalc?
Suncalc is an open-source JavaScript library developed by Vladimir Agafonkin for calculating the position of the sun and moon as well as sunlight phases (sunrise, sunset, dusk, etc) based on date, time and geographic location. It is designed to be lightweight, fast and have no dependencies, making Suncalc easy to integrate into web applications.
Some key features of Suncalc include:
- Calculate sunrise, sunset, dawn, dusk, solar noon, daylight length, moonrise and moonset times
- Get sun and moon position coordinates (azimuth, altitude)
- Moon phases and illumination percentage calculations
- Simple API with timezone and DST support
- No dependencies, small filesize (9KB gzipped)
- Works client-side in browser or server-side in Node.js
Suncalc provides an accurate solar position algorithm and has been tested against official data sources. It can account for atmospheric refraction during sunrise and sunset. The moon calculations are based on an accurate ephemeris model. There are no limitations or quotas.
Because of its lightweight footprint and ease of use, Suncalc is popular for integrating solar information into map tools, weather apps, calendars, automated home technology, solar energy projects and other web/mobile applications where sunrise, sunset or moon times are needed.
Suncalc Features
Features
- Calculates sun position
- Calculates sunlight phases
- Calculates moon position
- Calculates lunar phase
Pricing
- Open Source
Pros
Cons
Official Links
Reviews & Ratings
Login to ReviewThe Best Suncalc Alternatives
View all Suncalc alternatives with detailed comparison →
Top Science & Education and Astronomy & Space and other similar apps like Suncalc
Here are some alternatives to Suncalc:
Suggest an alternative ❐SunIZup
Sol: Sun Clock
Sun Surveyor
Sun Intervals
SUNSETWX