I recently rebuilt a marketing agency website using Astro 5 with server-side rendering, and I wanted to share the experience. The site is apexstudio.se — a Swedish SEO and web development agency.
Why Astro 5 for an Agency Site?
We had specific requirements:
- Fast initial page loads for SEO credibility (an SEO agency with a slow site? No thanks)
- Dynamic content for case studies and blog posts
- Minimal JavaScript shipped to the client
Astro's island architecture was perfect. Most pages are pure HTML/CSS with interactive components only where needed.
SSR on Railway + Cloudflare
We chose SSR over static generation because we wanted:
- Real-time content updates without rebuilds
- Dynamic meta tags based on request context
- Server-side redirects for multi-language support
The hosting stack:
Astro 5 (SSR mode) → Railway → Cloudflare (proxy + SSL)
Performance Numbers
- Lighthouse Performance: 98
- First Contentful Paint: 0.6s
- Total Blocking Time: 0ms (zero client JS on most pages)
- CLS: 0
Astro's partial hydration means we ship almost no JavaScript. The client gets pure HTML + CSS for most pages.
Astro 5 Features We Used
Content Collections
Perfect for blog posts and case studies:
const collection = defineCollection({
schema: z.object({
title: z.string(),
description: z.string(),
publishDate: z.date(),
}),
});
View Transitions
Smooth page transitions without a SPA:
<head>
<ViewTransitions />
</head>
Image Optimization
Astro's built-in <Image> component with automatic WebP conversion saved us tons of bandwidth.
Lessons Learned
- Astro 5 SSR is production-ready — stable, fast, and easy to deploy
- Islands architecture is perfect for marketing sites — most content is static anyway
- Railway + Cloudflare is an excellent hosting combo for SSR Astro
- Content collections make managing blog posts and case studies a breeze
Check out the result at apexstudio.se. If you're building a marketing or agency site, Astro 5 is worth considering.
What's your experience with Astro for business sites? Let me know in the comments!
Top comments (0)