SkyCast

Full-stack weather + COVID dashboard. Next.js frontend consumes a Python backend on a DigitalOcean droplet. Location-aware via browser geolocation.

By Aditya Singh Khichi, Full Stack Engineer, New Delhi, India.

Tech stack: Next.js, TypeScript, Python, DigitalOcean, REST.

Next.js + Python backend: Full-stack

Problem

Most weather dashboards call public APIs directly from the browser, which leaks API keys and ties the UX latency to the upstream provider's response time. I wanted a dashboard where the frontend never sees an upstream API key, and the backend can swap providers, batch requests, or cache responses without redeploying the frontend.

Approach

Next.js frontend with internal API routes (/api/weather, /api/covid) that proxy to a Python backend deployed on a DigitalOcean droplet. The backend owns the upstream API keys, the rate-limiting logic, and any caching. Frontend uses browser geolocation to grab lat/lon, then queries the right backend handler via a type discriminator. Clean architectural split: frontend stays React, backend stays Python, neither owns the other's concerns.

Outcome

A self-hosted full-stack data dashboard. The split paid off the first time the upstream weather provider rate-limited me — swapping the backend's source took 5 lines of Python, no frontend redeploy. The same architecture pattern (frontend proxies through your own backend, never directly to upstream) is the one I default to now for any data-fetching app.

Live link: https://github.com/Raghav-45/skycast