← All posts

One codebase, a hundred brands

How white-label SaaS adds a new customer with configuration, not a new project.

A new customer should be a row of configuration, not a new project. What changes per brand, what never does, and how to keep tenants apart.

White-label means one product sold under many names. Each customer gets their own brand, domain and settings, and every one of them runs on the same code.

Decide what varies per tenant

Write the list down early: name, logo, colours, domain, languages, currencies, prices and rules. Everything on that list lives in tenant configuration. Everything off it is the same for all tenants. If a feature request only makes sense as a code fork, it is a sign the list is missing something.

Find the tenant from the request

The usual key is the domain. When a request arrives, map its host to a tenant, load that tenant’s configuration, and carry it through the request. The rest of the app never guesses.

Keep data apart by default

Every tenant-owned row carries a tenant id, and every query filters by it. Database row level security is a good backstop: even if a query forgets the filter, the database refuses to return another tenant’s rows.

The pay-off

When the core improves, every brand gets it the same day. When a bug is fixed, it is fixed everywhere. Onboarding a new customer becomes configuration and a domain, not weeks of work.

Keep reading

  • AI Costs
  • Architecture

Why did my AI bill just triple?

One gateway, one hard cap, and the two leaks that cause most surprise bills.

Most surprise AI bills come from a few predictable places. A single gateway with logging, model routing and a hard monthly limit closes all of them.

  • Backend
  • Architecture

Why your microservices should stop shouting JSON

gRPC and Protocol Buffers in plain words, and where REST still wins.

Why services inside a system often talk gRPC instead of JSON over HTTP, what a .proto file gives you, and where REST still fits.

  • Email & DNS
  • Backend

Have you ever thought how email works?

One click on Send, six hops, five DNS records and a handshake in plain text.

You press Send and a second later it lands on the other side of the world. Here is the whole journey: SMTP, the servers it passes through, and the DNS records (MX, SPF, DKIM, DMARC) that decide whether it reaches the inbox or the spam folder.

Have a process worth automating?

Tell me what eats your team's week. I'll tell you what I'd automate first.

Start a project Remote · PrimeX Meta, Dubai · teams across time zones