Astro vs Next.js
Zero JavaScript by default for content-first sites, against a full React application framework built for interactivity.
2 min read
Astro and Next.js can both build a marketing site or a blog, but they start from opposite defaults about how much JavaScript a page should ship. That difference matters more than it sounds — it shapes which one you should actually reach for.
Zero JS by default vs. hydrate by default
Astro's core bet is that most pages are mostly static, so it ships none of the JavaScript needed to render a component's HTML — only the markup and CSS, unless you explicitly opt a specific component into interactivity ("islands architecture"):
---
// Astro — this component renders to plain HTML, no JS shipped
const posts = await getPosts();
---
<ul>{posts.map((p) => <li>{p.title}</li>)}</ul>Next.js, even with React Server Components reducing client-side JavaScript significantly compared to the old default, is still fundamentally an application framework built around React running in the browser for anything interactive — a Next.js page ships React's hydration machinery the moment any part of it needs client-side state.
Framework agnosticism
Astro doesn't care which UI library you use for interactive pieces — React, Vue, Svelte, or Solid components can all live side by side in the same Astro project, each hydrated independently only where needed. Next.js is React, full stop; that's a constraint if your team wants flexibility, but an advantage if you're already committed to React and want one consistent mental model everywhere.
What each one is actually for
Astro is built for content-heavy sites — blogs, documentation, marketing pages, portfolios — where the bulk of a page is words and images and only a widget or two needs to run in the browser. Next.js is built for applications — dashboards, authenticated products, anything with heavy client-side state and interactivity throughout the page, where React's component model earns its runtime cost.
Which should you learn first
Learn Astro first if you're building a content site where page speed and minimal JavaScript matter most — you'll get excellent performance with very little effort. Learn Next.js if you're building an interactive web application rather than a content site — Astro can bolt on interactive islands, but it isn't trying to be a full application framework the way Next.js is, and forcing a heavily interactive app into Astro's content-first model works against its design.
See What is Next.js? for how Next.js's rendering model and Server Components work.