WEB FRAMEWORKS

Astro

The web framework for content-driven websites — used by Google, Microsoft, and Porsche. Astro's island architecture ships zero JavaScript by default, supports any UI library (React, Vue, Svelte), and delivers unmatched performance for blogs, docs, and marketing sites.

Why It Matters

Most frameworks ship hundreds of KB of JavaScript even for static pages. Astro's Islands Architecture sends zero JS by default, hydrating only interactive components. With the highest Core Web Vitals pass rate (62%) of any major framework, it's objectively the fastest choice for content-driven sites where performance impacts revenue.

Core Features

Every feature that makes Astro the most complete web framework — explained in plain English so you know exactly what it does for your product.

Islands Architecture

Astro's signature innovation. Pages are rendered as pure static HTML by default. Interactive components ('islands') are selectively hydrated using client directives: client:load (immediately), client:idle (when idle), client:visible (when scrolled into view), client:media (at breakpoint), client:only (skip SSR). The static HTML loads instantly, and islands activate independently — no JavaScript waterfall.

What This Means For Your Business

Imagine a newspaper page — the articles, headlines, and images are static (no code needed). But the 'Subscribe' button, search bar, and live stock ticker need interactivity. Astro treats your website the same way: static content ships as lightweight HTML, and only the truly interactive parts (buttons, forms, widgets) get JavaScript. The result? Pages that are 5-10x faster than traditional frameworks.

Zero JavaScript by Default

Astro components (.astro files) render to HTML at build time with no JavaScript sent to the browser. Only components explicitly marked with a client: directive receive JavaScript. A typical Astro blog post sends 0KB of JS to the browser. A complex marketing page might send 20KB vs. 200KB+ from a traditional framework.

What This Means For Your Business

Most frameworks send huge amounts of code to your visitor's phone or laptop, making pages slow and heavy. Astro sends nothing by default — just fast, lightweight HTML. When a component truly needs interactivity (like a shopping cart or form), Astro adds just the code for that one component. The result: pages that load 5-10x faster.

UI Framework Agnostic

Use React, Vue, Svelte, Solid, Preact, Alpine.js, or plain Astro components — in the same project, on the same page. Official integrations (@astrojs/react, @astrojs/vue, @astrojs/svelte, @astrojs/solid-js, @astrojs/preact) let you bring existing components from any ecosystem. No rewriting, no vendor lock-in.

What This Means For Your Business

Unlike other frameworks that lock you into one ecosystem, Astro works with everything. Your team uses React? Use React components. Another team uses Vue? Use those too — on the same page if needed. Astro is the universal adapter for web components, giving you freedom to choose the best tool for each job.

Content Collections

Type-safe content management for Markdown, MDX, YAML, and JSON files. Define content schemas with Zod validation, get auto-complete and type-checking in your editor, and query content with a typed API. Supports frontmatter validation, relational references between collections, and custom loaders for external data sources (CMS, API, database).

What This Means For Your Business

Organize your blog posts, documentation pages, and product data with built-in type safety. Astro validates your content at build time — if a blog post is missing a title or has an invalid date, you know immediately, not after it's published. It's like having a proofreader for your content structure.

File-Based Routing

Pages in src/pages/ become routes automatically. Supports dynamic routes ([slug].astro), rest parameters ([...path].astro), and nested directories for hierarchical URLs. API endpoints via .ts/.js files. Static and dynamic routes can coexist.

What This Means For Your Business

Your website's URL structure matches your folder structure — create a file, get a page. Want /blog/hello-world? Create the file at the matching path. Intuitive, visual, and zero configuration needed.

View Transitions

Built-in View Transitions API support for smooth, animated page transitions. Shared element animations, fade/slide/morph transitions, and persistent elements across navigations — all without an animation library. Astro's ViewTransitions component provides cross-browser fallbacks and customization options.

What This Means For Your Business

When users navigate between pages, instead of jarring flashes, content smoothly animates — images morph, text fades, sidebars slide. These polished transitions make your website feel like a premium mobile app, without any complex animation code.

Built-in Image Optimization

The <Image /> component automatically optimizes local images: resizing, format conversion (WebP/AVIF), lazy loading, and responsive srcset generation. @astrojs/image provides remote image optimization with provider support (Cloudinary, Imgix). Prevents Cumulative Layout Shift (CLS) by enforcing dimensions.

What This Means For Your Business

Every image on your site is automatically compressed, resized for each device, and served in modern formats. A 5MB hero image becomes a 50KB file on mobile. Pages load faster, look sharper, and use less bandwidth — all without manual optimization.

Server-Side Rendering (On-Demand)

Enable SSR per page or globally for dynamic content. Server endpoints handle API logic. Works with adapters for Node.js, Vercel, Netlify, Cloudflare Workers, Deno, and AWS. Hybrid mode lets you mix static pre-rendered pages with dynamic server-rendered pages in the same project.

What This Means For Your Business

While Astro excels at static content, it handles dynamic pages too — personalized dashboards, user profiles, real-time data. Choose which pages are static (for speed) and which are dynamic (for freshness) — best of both worlds in one project.

Middleware

Run custom logic before every request — authentication, redirects, locale detection, analytics, A/B testing. Middleware has access to request/response objects and can modify headers, set cookies, and redirect. Runs on the server before the page renders.

What This Means For Your Business

Before any page loads, Astro can check if the user is logged in, which country they're in, or which version of a page to show them. All of this happens in milliseconds, before the visitor sees anything.

Actions (Type-Safe Backend)

Write type-safe backend functions that you call directly from your frontend client code. Actions handle form submissions, database writes, and API calls with built-in input validation (via Zod). Type safety flows from the action definition to the client call — no manual type synchronization.

What This Means For Your Business

Need to save a contact form or process a payment? Write a backend function and call it from your page — Astro handles the plumbing. The function definition and the frontend call share the same type information, so mistakes are caught at development time, not in production.

Starlight (Documentation Framework)

Astro's official documentation framework built on top of Astro. Full-featured docs out of the box: sidebar navigation, search (Pagefind), i18n, versioning, syntax highlighting, dark mode, and plugin system. Used by major projects including Astro's own documentation.

What This Means For Your Business

Need to build documentation for your product? Starlight gives you a beautiful, search-enabled, multi-language documentation site with minimal setup. It's what Astro's own docs are built with — and it's free.

Prefetching

Astro automatically prefetches pages when links enter the viewport or on hover. Choose from built-in presets: 'hover' (default), 'viewport', 'load', or 'tap'. Customize per-link with data-astro-prefetch attribute. Makes navigation feel instant.

What This Means For Your Business

When a link is visible on screen or hovered, Astro silently loads the destination page in the background. By the time the user clicks, the page is already loaded. Navigation feels instant — like flipping pages in a book.

Rendering Strategies

Astro offers 4 rendering strategies — more than any other framework. Choose the right approach for each page or component based on your performance and freshness needs.

Static Site Generation

SSG

Astro's default and primary mode. All pages are pre-rendered at build time as static HTML with zero JavaScript. Deploy to any static host. Fastest possible page loads, zero server costs, and infinitely cacheable. Content Collections provide type-safe content management for static sites.

In Plain English

Your entire website is built once during deployment, then served as lightweight HTML files. No servers, no processing, no waiting — visitors get instant page loads from anywhere in the world. The fastest and cheapest way to run a website.

Server-Side Rendering

SSR

Enable per page with export const prerender = false (in hybrid mode) or globally in astro.config.mjs. Works with adapters for Node.js, Vercel, Netlify, Cloudflare Workers, Deno. Each request is rendered server-side with fresh data.

In Plain English

For pages that need fresh data on every visit (personalized content, real-time dashboards), Astro renders them on the server just like Next.js or Nuxt do. You get the same dynamic capability when you need it, with static site speed everywhere else.

Hybrid Rendering

Hybrid

Mix static pre-rendered pages and dynamic server-rendered pages in the same project. Set output: 'hybrid' in config, then mark specific pages as dynamic with export const prerender = false. Marketing pages stay static while dashboards render dynamically.

In Plain English

Get the best of both worlds — your marketing pages and blog posts are pre-built for maximum speed, while your user dashboard and personalized pages are rendered fresh on each visit. Same project, different strategies per page.

Client-Side Rendering (Islands)

CSR

Interactive components hydrate client-side via island architecture. Astro renders the static shell, then individual interactive islands activate independently. Each island loads only the framework code it needs (React, Vue, Svelte, etc.) — no monolithic JS bundle.

In Plain English

Interactive parts of your page (shopping cart, search bar, chat widget) activate independently in the browser while the rest stays as fast static HTML. Each interactive piece loads only its own tiny amount of code — not the entire framework.

Built-in Optimizations

Astro ships with performance optimizations that would take weeks to configure manually — every one of them works out of the box, zero config.

Zero JS Default

Astro ships zero JavaScript by default — only the JS needed for interactive islands is sent to the browser. A typical Astro blog sends 0KB of client JS. Compare: a Next.js page sends 80-150KB baseline. Astro's approach means fundamentally faster pages and better Core Web Vitals.

In Plain English

Your visitors' devices do zero unnecessary work. Static content is just HTML — no code to download, parse, or execute. Only truly interactive features get JavaScript, and only the minimum needed. The result: the fastest possible page loads.

Automatic Image Optimization

Built-in <Image /> and <Picture /> components automatically resize, compress, and convert images to modern formats (WebP/AVIF). Lazy loading prevents below-fold images from blocking page load. Aspect ratio enforcement prevents CLS. Works with local and remote images.

In Plain English

Every image is automatically compressed and resized for each device. Mobile visitors get small images, desktop visitors get large ones. Images below the fold don't load until scrolled into view. Faster pages, less bandwidth, sharp images everywhere.

Intelligent Prefetching

Links are prefetched on hover or viewport entry with configurable strategies. Pages feel instant because data is pre-loaded before the click. Customizable per-link via data-astro-prefetch attribute.

In Plain English

Astro silently pre-loads the next page before you click, making navigation feel instant. It's like a concierge who opens doors before you get to them.

Automatic Code Splitting

Each island loads only its own code. React islands load React, Vue islands load Vue — no monolithic bundle containing every framework. Shared dependencies are deduplicated. Unused code is tree-shaken away.

In Plain English

Each interactive component on your page downloads only its own small amount of code — not the entire website's code. Smaller downloads mean faster loading, especially on mobile devices and slow connections.

Scoped CSS

Astro components have scoped styles by default — CSS written in a component only affects that component. No class name conflicts, no CSS-in-JS overhead, no external stylesheet. Supports Tailwind CSS, Sass, CSS Modules, and PostCSS.

In Plain English

Styles for each component are automatically isolated — changing one component's design never accidentally breaks another. No more debugging mysterious styling issues across your site.

File Conventions & Architecture

Astro's App Router uses the file system as the API. Each file convention has a specific purpose — create the file and the behavior is automatic.

app/ directory
src/pages/index.astro
Home Page

The root route (/). Every file in src/pages/ becomes a route. Supports .astro, .md, .mdx, .html, .ts, .js.

src/pages/[slug].astro
Dynamic Route

Brackets define dynamic URL segments. Must export getStaticPaths() for static generation. Access params via Astro.params.

src/layouts/Base.astro
Layout

Reusable page shells with header, footer, and shared UI. Used via <Layout> wrapper in pages. Supports named slots for content regions.

src/content/config.ts
Content Schema

Defines schemas for Content Collections using Zod. Validates frontmatter at build time. Provides type-safe querying for Markdown/MDX content.

src/components/*.astro
Components

Astro components render to HTML with zero JS. Import React/Vue/Svelte components alongside. Use client: directives for interactive islands.

src/middleware.ts
Middleware

Runs before every request for auth, redirects, locale detection. Has access to request context. Server-side only.

src/actions/index.ts
Server Actions

Type-safe backend functions callable from client code. Input validation via Zod. Handles form submissions and mutations.

astro.config.mjs
Configuration

Central config for integrations, adapters, output mode, image optimization, and all Astro settings.

Why Teams Choose Astro

The key advantages that make Astro the most adopted React framework — real differentiators, not marketing claims.

CategoryStrengthDetails
PerformanceFastest Core Web Vitals of Any Framework

62% of real-world Astro sites pass Core Web Vitals — beating WordPress (46%), Gatsby (45%), Next.js (29%), and Nuxt (25%). This isn't marketing; it's measured data from the HTTP Archive and Chrome UX Report across millions of real websites.

Zero JavaScript Default

Pages ship as pure HTML with 0KB of JavaScript by default. Interactive components load on-demand with fine-grained control (on load, on idle, on visible, on media query). The result: fundamentally faster Time to Interactive than any framework that ships a JS runtime.

FlexibilityUse Any UI Framework

React, Vue, Svelte, Solid, Preact, Alpine — all supported officially. Mix them on the same page. Bring existing components from any ecosystem without rewriting. No vendor lock-in. Your team's framework preferences are respected, not overridden.

ContentContent Collections + Starlight

Type-safe content management with schema validation, auto-generated types, and a queryable API. Starlight provides a production-ready documentation framework with search, i18n, versioning, and theming — the best documentation experience in the ecosystem.

Developer ExperienceSimple Mental Model

Astro components use HTML-first syntax — if you know HTML, you can write Astro. The frontmatter is just JavaScript/TypeScript. No complex state management, no hydration puzzles, no 'use client' boundaries. Components render to HTML and that's it — until you opt into interactivity.

SEOStatic HTML = Perfect SEO

Pre-rendered HTML is immediately indexable by search engines with zero waiting. No JavaScript execution needed for crawlers to see your content. Combined with the fastest Core Web Vitals, Astro sites consistently rank higher due to Google's performance-based ranking signals.

EcosystemGrowing Community & Adoption

57.4K GitHub stars, 1,041 contributors, and adoption by Google, Microsoft, Porsche, Visa, Unilever, OpenAI, The Guardian, NordVPN, and Cloudflare. Astro is the fastest-growing framework in the content-driven space with a vibrant community and ecosystem of themes, integrations, and partner agencies.

Deployment Options

Run Astro your way — fully managed on Vercel, self-hosted on your own infrastructure, exported as static files, containerized with Docker, or deployed to the edge.

Netlify

Astro's official deployment partner. Zero-config deployment with @astrojs/netlify adapter. SSR functions, edge functions, image CDN, forms, and preview deployments included.

In Plain English

Netlify is Astro's official deployment partner. Push to GitHub and your site goes live. Everything is handled automatically — builds, hosting, CDN, and SSL.

Vercel

Deploy with @astrojs/vercel adapter. Serverless and edge functions, preview deployments, CI/CD from Git. Automatic optimization with Vercel's global CDN.

In Plain English

Push your code and Vercel deploys it globally. Preview every change before it's live. Fast, reliable, and free for personal projects.

Cloudflare Pages

Deploy to Cloudflare's global edge network via @astrojs/cloudflare adapter. Runs on Cloudflare Workers for ultra-low latency. Integrates with KV, D1, R2, and Durable Objects.

In Plain English

Run your website on Cloudflare's worldwide network. Ultra-fast everywhere, with a generous free tier and integrations with Cloudflare's storage and database services.

Static Hosting (Any CDN)

Astro's default output is static HTML that deploys anywhere — GitHub Pages, AWS S3 + CloudFront, Firebase Hosting, Surge, or any web server. No adapter needed for static sites.

In Plain English

Astro static sites are just HTML files that deploy anywhere — even the cheapest hosting. No servers needed, virtually unhackable, and lightning fast from any CDN.

Self-Hosted (Node.js)

Deploy with @astrojs/node adapter to any Node.js server. Works with Docker, PM2, or systemd. Full SSR support for dynamic pages.

In Plain English

Run Astro on your own servers for full control. Works with Docker containers, traditional servers, or any Node.js hosting environment.

Integration Ecosystem

Astro integrates with 39+ tools across 10 categories — from headless CMS platforms to AI frameworks, databases, authentication providers, and more.

Content Management

8 integrations
PrismicContentfulSanityStrapiStoryblokWordPress (Headless)CloudCannonKeystatic

Search & Discovery

3 integrations
AlgoliaPagefindMeilisearch

Authentication

3 integrations
ClerkAuth.jsSupabase Auth

Databases & ORMs

4 integrations
PrismaDrizzle ORMSupabaseAstro DB

Deployment Platforms

5 integrations
VercelNetlifyCloudflareNode.jsDeno

Styling & CSS

8 integrations
ReactVueSvelteSolidPreactTailwind CSSSassUnoCSS

Testing Frameworks

3 integrations
VitestPlaywrightCypress

Analytics & Monitoring

3 integrations
PlausibleGoogle AnalyticsFathom

Payments

1 integrations
Stripe

Email

1 integrations
Resend
Official / First-PartyCommunity / Third-Party

Use Case Fit

See how Astro aligns with different web application use cases — from e-commerce storefronts to AI-powered SaaS products and enterprise portals.

E-Commerce
Good Fit
Marketing Sites
Strong Fit
SaaS Products
Possible Fit
Blogs & Content
Strong Fit
Documentation
Strong Fit
Dashboards
Possible Fit
AI Applications
Possible Fit
Multi-Tenant
Possible Fit
PWAs
Possible Fit
Enterprise Portals
Good Fit

Best Fit Industries

See which industries get the most value from Astro — and how it specifically addresses their web development needs.

Media & Publishing
Strong Fit

The Guardian, NBC News, and Proton chose Astro for content-heavy sites. Zero JS default means articles load instantly. Content Collections provide type-safe editorial workflows. SEO is maximized with pre-rendered HTML. Astro is the best framework for content that needs to rank and load fast.

Developer Tools & Documentation
Strong Fit

Starlight is the most capable documentation framework available — used by Astro, Cloudflare, and many major open-source projects. Content Collections + MDX support make technical writing a joy. Static output deploys anywhere with zero hosting costs.

Marketing & Agencies
Strong Fit

Marketing sites need speed for conversion rates and SEO. Astro delivers both with the highest Core Web Vitals pass rate. Use any UI framework your team prefers. Themes and partner agencies accelerate delivery. Static hosting keeps costs near zero.

E-Commerce (Content-Heavy)
Good Fit

Product pages, catalogs, and landing pages benefit from Astro's speed. Use React or Vue islands for interactive cart/checkout components. For full transactional e-commerce (inventory, auth, cart state), consider pairing Astro with a dedicated commerce backend or using Next.js/Nuxt.

Enterprise & Corporate
Good Fit

Google, Microsoft, Porsche, Visa, and Unilever use Astro for corporate websites. Static output meets security requirements (no server to attack). Multi-framework support means teams can use their preferred tools. Content Collections enforce content quality standards.

Community & Ecosystem

Astro has one of the largest developer communities in the frontend ecosystem — backed by active maintainers, extensive documentation, and a vibrant open-source ecosystem.

57.4KGitHub Stars
3.2KForks
1,041Contributors
1.2M+Weekly npm Downloads
25K+Discord Members

Pricing & Licensing

Free and open-source (MIT License) • Managed hosting: Deploy to Netlify, Vercel, Cloudflare — each with free tiers • Self-hosting: always free

Honest Trade-Offs

No technology is perfect. Here are the real limitations of Astro — so you make an informed decision, not a surprised one.

Not Designed for App-Like InteractivityMedium

Astro excels at content-driven sites but is not the best choice for highly interactive SPA-like applications (real-time dashboards, complex drag-and-drop interfaces, rich text editors). For heavy interactivity, Next.js, Remix, or SvelteKit are better fits. Astro shines where content dominates.

Islands Can Add Complexity for Interactive PagesLow

Managing state and communication between multiple islands on the same page requires careful architecture (shared stores, custom events). For pages that are mostly interactive, the islands model adds complexity that a SPA framework handles more naturally.

Build with Astro? Let's Talk.

Our team will help you architect, build, and optimize your Astro application — from initial setup to production-scale deployment that handles millions of users.