Skip to content

Solar System Explorer is a 3D web experience built with React, Three.js, and TypeScript. Explore eight planets, asteroid belts, and deep-space objects with realistic orbits, time controls, and smooth camera interactions. Multiple space themes and info panels keep it immersive and educational. ๐ŸŒŒ๐Ÿš€

Notifications You must be signed in to change notification settings

YakshTechs/Solar-System-Explorer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

4 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŒŒ Interactive Solar System Explorer

Solar System React Three.js TypeScript

A breathtaking 3D journey through our solar system and beyond

Live Demo โ€ข Features โ€ข Quick Start โ€ข Controls


โœจ What Makes This Special?

Ever wanted to explore space from your browser? This isn't just another solar system visualization - it's an interactive cosmic playground where you can:

  • ๐Ÿช Explore all 8 planets with scientifically accurate orbital mechanics
  • ๐ŸŒˆ Switch between 8 stunning space themes (from Classic Dark to Aurora Green)
  • ๐ŸŒŒ Discover deep space objects: black holes, wormholes, nebulae, pulsars, and more
  • โฑ๏ธ Control time itself with adjustable orbital speeds (0x to 10x)
  • ๐ŸŽฎ Fully interactive 3D controls - rotate, zoom, and pan freely
  • ๐Ÿ“š Learn as you explore with detailed information panels for every celestial body

๐ŸŽฌ Preview

     โœจ        ๐ŸŒ         โ˜„๏ธ
        ๐ŸŒž              
   ๐Ÿช              ๐ŸŒ™
        โญ    ๐ŸŒŒ    โญ

Imagine this, but in stunning 3D with real physics

๐Ÿš€ Features

๐ŸŒ Realistic Solar System

  • 8 Planets with accurate:
    • Orbital distances and periods
    • Rotation speeds and axial tilts
    • Colors and atmospheric effects
    • Moons (Earth's moon included!)
    • Planetary rings (Saturn & Uranus)
  • Asteroid Belt with 200+ animated asteroids
  • The Sun with dynamic glow and corona effects

๐ŸŒŒ Deep Space Objects

Toggle visibility of cosmic wonders:

  • ๐ŸŒŒ Milky Way Galaxy - Our home in the cosmos
  • โœจ Star Clusters - Globular clusters scattered across space
  • ๐Ÿ•ณ๏ธ Wormhole - Einstein-Rosen bridge (theoretical!)
  • โšซ Black Hole - With gravitational lensing effects
  • โ˜„๏ธ Comets - Orbiting with beautiful tails
  • ๐ŸŒซ๏ธ Nebulae - Stellar nurseries in vibrant colors
  • ๐Ÿ’ซ Pulsar - Rotating neutron star with beams
  • ๐ŸŒ  Shooting Stars - Meteors streaking across the sky
  • ๐Ÿ”ญ Distant Galaxies - Billions of light years away

๐ŸŽจ Customization

  • 8 Space Themes:
    • Classic Dark
    • Deep Blue
    • Cosmic Purple
    • Warm Nebula
    • Aurora Green
    • Blood Moon
    • Ice Cold
    • Galaxy Pink
  • Toggle orbits, labels, and individual space objects
  • Adjustable time speed (pause, slow-mo, or time-lapse)

๐Ÿ“– Educational Content

Click any planet or space object to learn:

  • Physical characteristics (size, mass, temperature)
  • Distance from Earth/Sun
  • Fascinating facts and trivia
  • Scientific classifications

๐Ÿ› ๏ธ Tech Stack

Built with cutting-edge web technologies:

  • React 19 - Latest React with concurrent features
  • Three.js - Powerful 3D graphics engine
  • React Three Fiber - React renderer for Three.js
  • React Three Drei - Useful helpers for R3F
  • TypeScript - Type-safe development
  • Tailwind CSS 4 - Modern utility-first styling
  • Vite - Lightning-fast build tool

๐Ÿ“ฆ Quick Start

Prerequisites

  • Node.js 18+ installed
  • npm or yarn package manager

Installation

# Clone the repository
git clone <your-repo-url>
cd solar-system-explorer

# Install dependencies
npm install

# Start the development server
npm run dev

Open http://localhost:5173 and start exploring! ๐Ÿš€

Build for Production

# Create optimized production build
npm run build

# Preview production build locally
npm run preview

๐ŸŽฎ Controls

Action Control
Rotate View Click + Drag
Zoom In/Out Mouse Wheel / Pinch
Pan Camera Right Click + Drag
Select Planet Click on any planet
View Info Click planet/object for details
Change Theme Click "Space Theme" button
Adjust Speed Use time speed slider
Toggle Objects Use "Space Objects" panel

๐ŸŽฏ Usage Tips

  1. Start Slow: Begin with 1x speed to appreciate the orbital mechanics
  2. Explore Themes: Try different color palettes - each creates a unique atmosphere
  3. Hide Clutter: Toggle off space objects for a cleaner view of the solar system
  4. Learn: Click everything! Each object has fascinating information
  5. Find Hidden Details: Zoom in close to planets to see surface details and atmospheres
  6. Time Travel: Crank up the speed to 10x and watch years pass in seconds

๐Ÿ“ Project Structure

src/
โ”œโ”€โ”€ components/
โ”‚   โ”œโ”€โ”€ Planet.tsx          # Individual planet component
โ”‚   โ”œโ”€โ”€ Sun.tsx             # Sun with corona effects
โ”‚   โ”œโ”€โ”€ SolarSystem.tsx     # Main solar system orchestrator
โ”‚   โ”œโ”€โ”€ SpaceObjects.tsx    # Deep space objects (black holes, nebulae, etc.)
โ”‚   โ”œโ”€โ”€ PlanetInfo.tsx      # Planet information panel
โ”‚   โ””โ”€โ”€ SpaceObjectInfo.tsx # Space object information panel
โ”œโ”€โ”€ data/
โ”‚   โ””โ”€โ”€ spaceObjects.ts     # Educational content and data
โ”œโ”€โ”€ utils/
โ”‚   โ””โ”€โ”€ cn.ts               # Utility functions
โ”œโ”€โ”€ App.tsx                 # Main application component
โ”œโ”€โ”€ main.tsx                # Application entry point
โ””โ”€โ”€ index.css               # Global styles

๐ŸŽจ Customization

Adding a New Planet

Edit src/components/SolarSystem.tsx:

const PLANETS_DATA = [
  // ... existing planets
  {
    name: 'YourPlanet',
    radius: 1.5,
    distance: 45,
    orbitalPeriod: 1000,
    rotationPeriod: 2,
    colors: ['#FF0000', '#00FF00'],
    tilt: 15,
    eccentricity: 0.05,
  }
];

Creating a New Theme

Edit the SPACE_PALETTES array in src/App.tsx:

{
  name: 'Your Theme',
  bg: '#000000',
  stars: '#ffffff',
  nebula: '#1a0033',
  accent: '#4a00e0',
  nebulaColors: ['#4a00e0', '#1a0033', '#6600ff']
}

๐Ÿค Contributing

Contributions are welcome! Here are some ideas:

  • ๐ŸŒ™ Add more moons to other planets
  • ๐Ÿ›ธ Include spacecraft or satellites
  • ๐ŸŒŸ Add more space phenomena (supernovae, quasars)
  • ๐Ÿ“ฑ Improve mobile responsiveness
  • ๐ŸŽต Add ambient space sounds
  • ๐ŸŒ Internationalization support

๐Ÿ“ License

This project is open source and available under the MIT License.

๐Ÿ™ Acknowledgments

  • Planetary data based on NASA's solar system exploration
  • Three.js community for amazing 3D capabilities
  • React Three Fiber team for the excellent React integration

๐Ÿ› Known Issues

  • Performance may vary on older devices (3D rendering is intensive)
  • Some space objects may overlap at certain camera angles
  • Mobile touch controls could be improved

๐Ÿ“ฎ Contact

Have questions or suggestions? Feel free to open an issue! OR you can mail me at yaksh.inbox@gmail.com


Made with โค๏ธ by Yaksh Devani

"The cosmos is within us. We are made of star-stuff." - Carl Sagan

โญ Star this repo if you enjoyed exploring space!

About

Solar System Explorer is a 3D web experience built with React, Three.js, and TypeScript. Explore eight planets, asteroid belts, and deep-space objects with realistic orbits, time controls, and smooth camera interactions. Multiple space themes and info panels keep it immersive and educational. ๐ŸŒŒ๐Ÿš€

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published