Introduction

I decided to build my blog with Astro and deploy it to Cloudflare Pages from a GitHub repository. For a technical blog, this combination feels like a pragmatic choice: it is simple enough to understand, quick to load, and does not require much maintenance.

Astro and Wordpress

Back then when I had some personal pages, I usually created them on Worpress. I still like Wordpress and the whole ecosystem around it very much. But now I decided to go for a total simplicity. No database, no installation, no plugins, no mangement panel. Just plain code and deployment from repository to a static web page.

WordPress is still an excellent choice when content editors and business users need a familiar CMS. For a developer-first blog, Astro removes much of the operational overhead—no plugin maintenance, no database, and a much simpler deployment pipeline. The trade-off is that content management moves into Git, which is a feature for developers but a drawback for non-technical authors.

This comparison table should give you a better picture:

Astro vs typical CMS — A Practical Comparison

Astro is a web framework designed for content-focused sites. It can generate fast static pages, while still leaving room for interactive features when they are genuinely useful. I can write posts in Markdown and keep the content close to the code.

GitHub stores the project and its deployment settings. When I push a change, Cloudflare can build the site and publish it through Pages. That gives me a straightforward path from editing an article to making it available online.

Real Maintenance Cost: Small classical CMS vs Astro

One of the biggest reasons I chose Astro wasn’t performance — it was the long-term maintenance cost.

What my blog actually needs

For a simple technical blog, Astro dramatically reduces the operational overhead. There is no database to maintain, no plugins to update, and no caching layer to configure.

For a personal blog like Pragmatic by Default, the infrastructure cost is effectively close to zero on Cloudflare Pages’ free tier, while still benefiting from global edge delivery and automatic deployments from GitHub.

The whole project can be set up with help from tools such as GitHub Copilot or Claude Code. One useful lesson from my own setup is to be explicit: ask for a simple static blog. Otherwise, an AI assistant may introduce more infrastructure than the site actually needs.

Running Astro locally

The project page is Astro.

After cloning the repository, install its dependencies with:

npm installTo start Astro locally, run:

npm run devThis starts a local development server, usually available at

http://localhost:4321. It is useful for writing posts and checking changes

in a browser before publishing them.

Before deploying, run:

npm run buildThis creates the production version of the site and checks that the project can

be built successfully. In a simple workflow, npm run dev is for daily editing

and npm run build is for a final check before deployment.

For me, that is the appeal of Astro and Cloudflare. The technology is capable enough to grow with the blog, but stays out of the way of writing and publishing. If you want to add features like sitemap, it can be esily done using AI as well.

Deployment to CloudFlare Pages

The Cloudflare dashboard shows the project, its connected domain, and the deployment status in one place. I do not need to manage a server directly: every push to GitHub automatically triggers a new deployment.

How the deployment works

- Create a Cloudflare Pages project and connect it to your GitHub repository.

- Select the production branch (for example, main) that should trigger deployments.

- Configure the build settings:

- Framework preset: Astro

- Build command: npm run build

- Build output directory: dist

- Deploy the first build. Cloudflare installs dependencies, builds the project, and publishes the generated static files to its global edge network.

- Attach a custom domain from the Pages dashboard. Cloudflare automatically provisions and renews the SSL certificate.

- Keep shipping through Git. Every commit pushed to the production branch creates a new deployment, while pull requests can generate preview deployments for testing.

Why I like this setup

The deployment pipeline is intentionally simple:

GitHub → Cloudflare Pages → Global CDN → Your domain

There is no VPS to maintain, no FTP uploads, no PHP runtime, and no database. The entire deployment process is driven by Git, which makes rollbacks and previews straightforward.

Astro, GitHub, Cloudflare, and Cloudflare Pages are trademarks of their respective owners. This article is an independent technical tutorial and is not affiliated with or endorsed by those companies.