Infrastructure

Edge hosting: Cloudflare in front, Supabase behind, placement chosen for you

"Fast" on the modern web is mostly a question of geography: how far the request travels, and how many times it travels. GoGee's hosting model is built to reduce both.

GoGee feature series · 32 of 33

How it's actually built

Runtime
Cloudflare Workers
Placement
Smart placement enabled, so the worker runs near the data
Database
Supabase Postgres
Static assets
Served from the global edge network
Rendering
Server-side rendered application routes
TLS and DDoS
Handled at the edge
How the pieces connect
  1. 01Input

    Runtime

    Cloudflare Workers

  2. 02Deterministic

    Placement

    Smart placement enabled, so the worker runs near the data

  3. 03Deterministic

    Database

    Supabase Postgres

  4. 04Deterministic

    Static assets

    Served from the global edge network

  5. 05Output

    Rendering

    Server-side rendered application routes

Edge-fast everywhere, data flow, generated from the shared GoGee feature diagram template.

Smart placement is the important detail

Running code at the edge is only fast when the code does not need the database. A page that makes several database queries is faster when the worker runs near the database and returns one response to the visitor, instead of running near the visitor and making several long round trips. Smart placement makes that decision automatically per route.

  • Static assets served from the nearest edge location
  • Database-heavy routes executed close to Postgres
  • One response over the long leg instead of several

What that means for a South African audience

For visitors in South Africa hitting a site whose database sits offshore, the difference between one round trip and six is the difference between a page that feels instant and a page that feels broken on mobile data. That is the specific problem this configuration solves.

Operational side effects

TLS, caching and DDoS protection are handled at the edge rather than by a server you maintain, and deployments are atomic, a release either takes effect or it does not. There is no server to patch on a Friday night.

Questions we get asked

Where is the database?

On Supabase Postgres, with worker placement chosen so database-heavy routes run close to it.

Do I manage a server?

No. The application runs on Cloudflare Workers with TLS, caching and DDoS protection at the edge.

Is the site server-side rendered?

Yes, application routes are rendered on the server, with static assets served from the edge network.