Categories
Design

How to Build a Fast Local Business Website with Astro and Cloudflare Pages



Many local business websites are slow, and they don’t need to be. A plumber, a landscaper, or a damp-proofing company doesn’t need a heavy content management system loading a dozen scripts before the phone number shows up. For a site that’s mostly fixed information — services, areas covered, a contact form — a static site built with Astro and hosted free on Cloudflare Pages loads almost instantly and costs nothing to run.

Here’s the approach I’ve been using for local service sites.

Why static beats a database-driven CMS here

A traditional WordPress site builds every page on request: PHP runs, the database gets queried, the page gets assembled, then sent. That’s the right trade-off when content changes constantly or lots of people are logged in. A local trades site isn’t that. The services page in January is the same in June.

Astro builds every page once, ahead of time, into plain HTML. There’s no database to query and no server-side work when someone visits, so pages arrive as fast as the host can send them. On Cloudflare’s network that means they’re served from a data centre near the visitor, which for a local business chasing local customers is exactly what you want.

The stack

  • Astro for the site itself. It’s built for content-heavy sites and ships almost no JavaScript by default, so you’re not paying a speed penalty for a framework you barely use.

  • Cloudflare Pages for hosting. The free tier is genuinely enough for a local business site, and it deploys straight from a GitHub repository — push a change, the site rebuilds and goes live in under a minute.

  • A form service for the contact form, since a static site has no back end of its own to process submissions. Something like Web3Forms handles that without a server.

What a finished one looks like

A damp-proofing site for Brighton and Hove was built on exactly this stack — service pages, individual area pages for each town it covers, a set of guides, structured data for search engines, and a working contact form, all static, all served from Cloudflare’s edge. It’s a useful reference for what the setup produces: fast pages, clean markup, and no monthly hosting bill.

Worth doing if…

This isn’t the right build for every site. If the owner needs to log in and edit pages themselves every week, a CMS still earns its place. But for a local business where the content is fairly settled and speed and running cost matter, static is hard to beat. You get a site that loads instantly, costs nothing to host, and has very little that can break or need patching.

If you’re comfortable with a GitHub repository and a bit of the command line, it’s a weekend build. If you’re not, it’s a good brief to hand a developer — the stack is well documented and widely used.

Categories
Design

Trend Watch: Expanding and Contracting Headers

When a new design feature makes its way into one WordPress theme, it doesn’t take long for it to gain traction and spread like wildfire through the rest of the theme development community.

The latest WordPress theme trend that seems to be taking off right about now is expanding and contracting header menu areas (for want of a better name). This follows on from the fixed/floating header menu trend that while useful, was probably due a refresh in the fast passed world of theme development.

You can see it used in anger on many sites now including the PushUp desktop notifications service website, and if you are looking for a quality theme with this feature then the Centric Pro Genesis child theme from StudioPress.

Personally I find this animated feature a little distracting – what do you think?