About
Projects
BlogWhere I write, think and learn.GallerySometimes I also take photos.WrappedA recap of what's been on rotation lately.
Blog
Gallery
Wrapped
© 2026 /Gilang Fatahilah

Orbitari: Interactive 3D Model Solar System

Avatar
Gilang FatahilahNovember 14, 2026
Orbitari: Interactive 3D Model Solar System

Introduction

Orbitari is a 3D model of the Solar System that runs entirely in the browser. Pick any date between the years 1 and 9999 and every planet, moon, dwarf planet, and comet sits where it really was (or will be) at that moment. There is no backend: the site is a static build served from Cloudflare Workers, and all positions are computed on the client. The scene holds the Sun, eight planets, 21 major moons, Ceres, Vesta, Pluto and its five moons, four comets, about 35,000 real asteroids and Kuiper belt objects, and close to 9,000 catalog stars.

Key Features

  • Real positions for any date: positions, axial tilt, and rotation come from astronomy-engine. Time can play forward or backward from 1 day to 1 year per second.
  • Real small-body data: the asteroid belt (15,000 objects), Jupiter's Trojans (~11,600), the Hilda group (~2,900), and the Kuiper belt (~6,000) are built from JPL Small-Body Database orbital elements, packed into small binary files.
  • Focus and follow: clicking a body flies the camera to it and keeps following it, with an info panel of facts. A guided tour visits eight stops.
  • Size comparison mode: lines up every shown body side by side at true relative size, Sun included.
  • Astronomical events: eclipses, oppositions, elongations, equinoxes and solstices, comet perihelia, and meteor shower peaks for the simulated year. Choosing one jumps time to that moment.
  • Shareable views: the URL follows the view, so a link like /?focus=Saturn&t=1969-07-20T20:17Z opens on Saturn, paused at that moment.
  • Visual detail: Earth has city lights on its night side, clouds, and glossy oceans. Saturn's rings cast a shadow on the planet and the planet casts one on the rings. Comets grow a coma and two tails as they near the Sun.
  • English and Indonesian, picked from the browser language or in Settings.

Technologies Used

  • SvelteKit + adapter-static: the whole site prerenders to static files, with no server code.
  • Three.js + Threlte: the 3D scene, written as Svelte components.
  • astronomy-engine: planet and moon positions, rotation, and event searches (eclipses, oppositions, seasons).
  • postprocessing: bloom around the Sun.
  • Tailwind CSS: the UI panels and controls.
  • Vitest: unit tests for the orbital math, date handling, and URL parsing.
  • Cloudflare Workers static assets: hosting.

Challenges and Learnings

Keeping resonant groups in shape. Jupiter's Trojans and the Hildas are held in place by resonance with Jupiter. A plain two-body orbit for each object ignores that pull, so the groups would lose their shape as time runs. They move at their resonant rate instead (Jupiter's rate for the Trojans, 3/2 of it for the Hildas), so the clouds at L4/L5 and the Hilda triangle keep their shape for any date. Tens of thousands of objects on a phone. Asteroids are drawn as points from afar and switch to 3D rocks only up close. A quality setting picks High or Medium from the device type and steps down by itself when the frame rate drops. A flagship phone holds 56–60 fps; mid-range Android is still being tested. Scale. Real distances make planets invisible next to the orbits. The default view compresses distances and sizes, and a toggle switches to true scale, where planets in the overview become colored dots that stay clickable. Link previews for a client-only app. The app renders only on the client, so the prerendered HTML has no page content. Search and Open Graph tags live in the HTML template itself, since crawlers do not run JavaScript.

Outcome

Orbitari is live at orbitari.gff.workers.dev. Building it taught me how to turn real scientific data into something people can explore, and how to keep a large 3D scene smooth on a phone without a backend to lean on.
Open live site

Related projects

CISST: Real-time Night Sky Dashboard

CISST: Real-time Night Sky Dashboard

April 17, 2026A location-aware astronomy dashboard that tells you what's visible in the night sky tonight, combining real-time weather data with client-side astronomical calculations.
Typescript
React js
Tailwind CSS
Vite
Avatar
Read moreView project
Nabungo: Building a Personal Finance App from Scratch

Nabungo: Building a Personal Finance App from Scratch

August 28, 2025Nabungo is a full-stack personal finance management app I built to solve my own money tracking problems, from zero idea to production using Laravel, Vue 3, and Inertia.js.
Laravel
Vue js
TypeScript
Tailwind CSS
PostgreSQL
Inertia.js
Avatar
Read moreView project
Kaiwaa: Real-Time Chat App with Socket.IO & MongoDB

Kaiwaa: Real-Time Chat App with Socket.IO & MongoDB

December 11, 2024Building a scalable real-time chat application using Socket.IO, Express, MongoDB, and JWT authentication with a modern full-stack architecture.
Typescript
React js
Tailwind CSS
Vite
Express
Mongo DB
Socket IO
Avatar
Read moreView project