Muhammad Fahad.
Serverless · JAMstack

Serverless CMS on Astro & Cloudflare

A website with a full admin panel but no server to run: pages are pre-built with Astro, content is edited through a Git-based CMS, and visitor messages are stored in Cloudflare D1, all deployed on Cloudflare Pages.

Company
Independent project
Role
Architect and developer
Period
2026
Team
Built single-handedly

The challenge

Small business and personal websites need easy content editing, good SEO and low running costs. Paying for and maintaining an always-on server and database is too much for a site that mostly shows content.

What I built

  • Astro front end that turns Markdown content into fast static HTML pages.
  • Git-based admin panel at /admin: editors write in a form-style editor, and publishing saves the content as files in GitHub.
  • Automatic build and deploy on Cloudflare Pages for every commit.
  • Serverless API with Cloudflare Pages Functions for forms.
  • Cloudflare D1 (SQLite) database that keeps visitor queries and their history.
  • SEO built in: title and description per page from front matter, sitemap, robots.txt and Open Graph tags.

Technical highlights

  • Two data stores by design: website content in Git (versioned and reviewable), visitor data in D1 (queryable with SQL).
  • Static pages served from Cloudflare's global network: fast to load, with a small attack surface.
  • This portfolio uses the same approach: static pages on Cloudflare Pages, with the contact form saving to D1.

Results

0servers to run or patch
Gitfull history of every content change
SQLqueryable history of visitor messages