Appearance

Visual style

Mode
Theme
Accent
Advanced
Text sizeScales the whole site
16 px
Reduce motionReduce animations or match your system
Separate light and darkChoose a theme, accent and font for each
50

Technology · Frontend

Astro website development

Astro is an open-source web framework for content-driven websites. Its documentation describes a server-first approach that renders pages to HTML and ships no client-side JavaScript by default, with interactive 'islands' that can use React, Vue, Svelte or plain scripts.

In practice

How I use Astro

Astro is my default for brand, hospitality, retail and portfolio websites: Eastern Condiments' 520-page rebuild, Fresh Can, Seashells & Stories, Villa Laguna, Venora Dubai, ORVAS, M LOFT, and this portfolio itself. I pair it with typed content files, Vitest for content integrity tests and Playwright for end-to-end checks against the production build.

Why Astro is my default for websites

Most business websites are content plus a few interactive parts, such as a gallery, a booking enquiry or a filter. Astro is designed for that. Pages render to HTML at build time, and only the interactive parts load JavaScript.

On motion-heavy builds this matters even more. Eastern Condiments uses GSAP, ScrollTrigger, Lenis and Matter.js, but all of it is lazy-loaded through data-* hooks, and every module respects prefers-reduced-motion, so the content is readable before, and without, any of it.

A content model instead of hardcoded pages

I keep editorial content out of components. A typical project has:

  • src/content/…: typed copy, navigation, products, listings and SEO fields.
  • src/assets/…: source images, which Astro converts to AVIF/WebP at several widths.
  • Unit tests that assert content integrity: unique slugs, every image present, every internal reference resolving.

On the Eastern rebuild, those tests also assert that every one of the 442 URLs in the original site’s sitemap is either rebuilt or redirected to a real page.

Illustrative example: a typed collection with references

// src/content/config.ts
import { defineCollection, reference, z } from "astro:content";

const projects = defineCollection({
  type: "content",
  schema: ({ image }) => z.object({
    title: z.string(),
    cover: image(),                              // must exist, gets optimised
    technologies: z.array(reference("technologies")), // must point at a real entry
  }),
});

Where I don’t use Astro

When a product needs authenticated users, carts, real-time dashboards or lots of client state, I use Next.js. Astro can host islands of that, but past a certain point you’re rebuilding an app framework inside a site framework.

Trade-offs

Where Astro shines, and where it doesn't

Strengths

  • Pages are plain HTML by default, so content is fully present in the initial response for users and crawlers.
  • Content collections give typed, validated content without a CMS.
  • Built-in image pipeline outputs AVIF/WebP at responsive sizes.
  • Interactive components can be added as islands without turning the whole site into a single-page app.

Limitations

  • Not designed for app-like products with lots of shared client state; Next.js fits those better.
  • Without a CMS, non-technical editors need a workflow (Git-based CMS or a headless CMS) to update content.

Evidence

Projects using Astro

All work →

Sources

Official documentation

General descriptions on this page are based on the official documentation linked below. Experience notes are my own.

FAQ

Astro questions

Astro or Next.js for a business website?

For a website that is mostly content (services, rooms, products, articles), Astro. It ships less JavaScript and the defaults favour performance. If the site needs accounts, dashboards or per-user data, Next.js is the better fit, and the two can coexist on different subdomains.

Can an Astro site be edited without a developer?

Yes, with a CMS connected. Astro works with Git-based CMSs and headless CMSs. For small sites, I often keep content in typed files and handle updates as part of a maintenance plan, which avoids paying for a CMS that's rarely used.

Is Astro good for SEO?

It's a strong foundation: server-rendered HTML, no JavaScript required to read content, fast pages and full control over metadata. The rest (titles, internal links, structured data, content quality) still has to be designed deliberately.

What are Astro islands?

Islands are interactive components (React, Vue, Svelte or plain scripts) embedded in otherwise static HTML. Each island hydrates on its own, on page load, when visible or when idle, so only the interactive parts ship JavaScript. This site's project browser and skills tabs are React islands.

Need a Astro developer?

If your project needs Astro, send a short description of what you're building and where it's stuck. I'll reply with how I'd approach it.