3 FPS
Nathan Atherton
Back to Blog
Side Project

Building Wigan Weather: A Full-Stack Weather Intelligence App

Nathan Athertonยท Staff Software EngineerApril 2, 20266 min read

This project started with a friend. He built a weather app for a small town in Germany - a neat little tool that pulled in forecasts, conditions, and some local data. I thought it'd be interesting to see what I could build for Wigan. Not competition, just friendly inspiration. "You did yours, let me do mine."

What started as a quick weekend build turned into a surprisingly complete full-stack app - and the most interesting part wasn't the features. It was keeping the entire thing running on free-tier services.

The Cost-First Architecture

I made a deliberate decision early on: this app would cost me nothing to run. Not "cheap" - actually zero. That constraint shaped every technical decision.

The typical approach for a weather app would be to spin up a Node server on a VPS, connect a database, call a weather API, and serve a React frontend. That works, but even a small VPS costs a few dollars a month, and most weather APIs charge after a certain number of requests.

Instead, I went with an architecture built entirely on free tiers:

  • Cloudflare Workers for the backend - 100,000 requests/day on the free tier, 0ms cold starts (because there are no cold starts - it runs at the edge), and global distribution. This was the key decision. No server to manage, no cold start penalty, and more than enough capacity for a local weather app.
  • Supabase for data storage - the free tier gives you a Postgres database with 500MB of storage and 2GB of bandwidth. More than enough for caching weather data and storing user preferences.
  • Open-Meteo for weather data - completely free, no API key required, and surprisingly good data quality. It pulls from national weather services and provides hourly and daily forecasts.
  • Hono as the web framework on Cloudflare Workers - lightweight, fast, and designed for edge computing. Express-like API but built for the modern edge runtime.

The result is an app that handles thousands of requests a day without costing me a penny. The edge computing model means responses are fast regardless of where you access it from, and the smart caching layer means I'm not hammering the weather APIs unnecessarily.

What It Actually Does

The app is more than just "what's the temperature in Wigan right now." Here's the full feature set:

  • Current conditions - temperature, feels-like, humidity, wind speed and direction, pressure, UV index, and visibility
  • 48-hour hourly forecast - hour-by-hour breakdown with precipitation probability, wind, and temperature trends
  • 7-day daily forecast - high/low temps, precipitation, sunrise/sunset times
  • River Douglas water levels - this was a fun one. Wigan sits on the River Douglas, and flooding is a real concern. The app pulls live water level data and shows whether the river is at normal, elevated, or concerning levels
  • Radar maps - built with Leaflet, showing precipitation radar overlaid on a map of the Wigan area. You can see rain moving across the region in near real-time
  • Push notifications - weather alerts for severe conditions, heavy rain warnings, and frost alerts

The Stripe Experiment

One feature that stands out is the premium tier with Stripe integration. I want to be upfront about this - the premium subscription wasn't built because I thought Wigan Weather was going to be a business. It was a learning exercise.

I'd never built a payment flow from scratch before. Webhooks, subscription management, customer portals, handling failed payments, proration - these are things I'd worked around but never directly implemented. Wigan Weather gave me a low-stakes environment to learn all of it.

The premium tier offers extended 14-day forecasts, historical weather data, and ad-free access. Setting up the Stripe integration taught me more about payment architecture than any tutorial could have - because when real money (even test mode money) is involved, you think about edge cases differently.

The Tech Stack

Here's the full breakdown:

  • Frontend: React 19, Vite, Tailwind CSS
  • Backend: Cloudflare Workers with Hono framework
  • Database: Supabase (Postgres)
  • Weather data: Open-Meteo API
  • Maps: Leaflet with OpenStreetMap tiles
  • Payments: Stripe (subscriptions, webhooks, customer portal)
  • Notifications: Web Push API

React 19 was a natural choice - the new features around server components and improved suspense handling made the data-heavy dashboard feel smooth. Tailwind kept the styling fast and consistent. And Vite made the dev experience painless.

The Edge Computing Advantage

One thing I didn't fully appreciate before this project is how much edge computing changes the game for small apps. Traditional server-based architectures have a fixed cost floor - even if nobody uses your app, you're paying for the server. Cloudflare Workers flip that model: you pay per request (and the free tier is generous enough that "pay" is theoretical for most side projects).

The 0ms cold start is the other game-changer. Lambda functions and similar serverless platforms have cold starts that can add 200-500ms to the first request. For a weather app where people want instant results, that matters. Workers run at the edge, already warm, in the data centre closest to the user. The response times are consistently fast.

Lessons Learned

Building Wigan Weather reinforced something I keep coming back to: constraints breed creativity. The "zero cost" constraint forced me into an architecture that turned out to be better than what I would have built without it. Edge computing, smart caching, free-tier services - these aren't compromises. They're genuinely good engineering choices that I might not have made if I'd just thrown money at a VPS.

The other lesson is that side projects don't need to be ambitious to be valuable. This wasn't a startup idea or a portfolio showpiece. It was "my friend built a cool thing, let me build one too." And in the process, I learned Cloudflare Workers, deepened my Supabase knowledge, built my first Stripe integration, and shipped a complete product.

The app is done now. I don't have plans to add more features or turn it into anything bigger. It works, it's useful for checking the weather in Wigan, and it taught me a lot. Sometimes that's exactly what a project should be.