Skip to content
Blog

Astro vs Next.js for marketing, portfolio and content sites (2026)

Astro vs Next.js for marketing and portfolio sites: JS shipped, content workflow, i18n, hosting and DX, plus when Next.js is still the right call.

Comparison 10 min read astronextjsframeworksweb performancecomparison
A diagonal split illustration: the Astro logo over scattered island blobs on one side, the Next.js logo over a component tree on the other.

Most Astro vs Next.js comparisons are written by someone defending the framework they already picked. I have shipped with both. I used Next.js for an exam platform with in-browser AI proctoring during my internship at PT Artristik Studio and in client work, and I built the site you are reading on Astro.

My answer is not “Astro is faster” or “Next.js scales better”. It comes down to one question: is the thing you are building a document or an app?

The short answer

If the site is mostly pages people read (a landing page, a portfolio, a blog, docs, a company profile), pick Astro. You get less JavaScript by default, a content workflow that is built in rather than assembled, and output you can host anywhere as plain files.

If the site is really a product with a marketing page attached (logins, per-user data, dashboards, forms that write to a database on every screen), pick Next.js. Its whole model is built around React on the server and the client, and that is exactly what an app needs.

Where both frameworks stand in November 2026

Both move quickly, so here is the state at the time of writing.

Astro is on the 7.x line. Astro 7.4 shipped in October 2026, after Astro 7.0 in June brought a Rust compiler and Vite 8. Astro 6 (March 2026) made live content collections, the CSP API and a built-in Fonts API stable. In January 2026 Cloudflare acquired the team behind Astro. The framework stays open source under the MIT licence and still deploys to other hosts.

Next.js is on 16.x. Next.js 16.4 (October 2026) recommends Cache Components for every app. New apps from create-next-app have it on by default, and the team says it becomes the default in Next.js 17. The App Router is the standard way to build.

One honest note: this site still runs Astro 5. Nothing below depends on a 6 or 7 feature. The concepts I compare (islands, content collections, static output) have been stable since Astro 5.

JavaScript shipped: the default matters more than the ceiling

People argue about which framework can produce the smallest bundle. That is the wrong fight. With enough effort both can ship a fast page. What matters is what you get when you are tired, on a deadline, and just adding one more section.

Astro renders every component to HTML at build time and ships zero JavaScript for it unless you ask. When you need interactivity you mark that one component as an island with a directive like client:idle or client:visible, and only that component hydrates.

On this site, the React islands are the mega-menu, the animated blob and a few interactive tiles. Everything else is static HTML with small motion scripts for reveals. The architecture doc for this repo literally sets an islands budget, and keeping to it costs nothing, because the default is already zero.

With Astro, every byte of JavaScript is a decision you made. With Next.js, it is the starting point you trim from.

Next.js has narrowed the gap. Server Components render on the server and send no component code to the browser. But an App Router page still loads React and the Next.js router on the client, because fast client-side navigation is part of the deal. For an app that is a feature. For a five-page marketing site that people visit once from a LinkedIn link, it is weight that buys you very little.

Content workflow

This is where Astro wins most clearly for content sites, and it gets less attention than performance.

Astro has content collections built in. You point a loader at a folder of Markdown or MDX, describe the frontmatter with a Zod schema, and get typed entries back. Here is the shared part of the schema this site uses:

const seo = {
  title: z.string().min(1).max(100),
  description: z.string().min(20).max(200),
  ogTitle: z.string().max(70).optional(),
  ogTag: z.string().max(24).optional(),
  draft: z.boolean().default(false),
};

If a post has a 15-character description, the build fails and names the file. A missing meta description never reaches production, because it never gets past the build. The same collections feed the blog index, the RSS feed, a hand-rolled sitemap and the build-time OG images, which are rendered with satori and resvg from each entry’s ogTitle and ogTag.

When content lives in a CMS instead of git, the content layer loaders and the live content collections (stable since Astro 6) cover that case without changing how pages read the data.

Next.js can do all of this too, but you assemble it. MDX support comes from @next/mdx or a library of your choice, frontmatter validation is something you add, and the loader that turns a folder into typed entries is code you write and maintain. None of it is hard. It is just work Astro has already done.

Internationalisation

This site has English at / and Indonesian at /id/. In Astro that is a few lines of config:

i18n: { defaultLocale: 'en', locales: ['en', 'id'], routing: { prefixDefaultLocale: false } },

Astro’s i18n routing gives you helpers for locale paths, and the rest is yours: on this site, each page emits canonical and hreflang tags, and the sitemap lists both locales with x-default alternates.

The App Router has no built-in i18n routing config. The official Next.js guide has you detect the locale in Proxy (the file formerly known as middleware), nest every route under app/[lang], and use generateStaticParams to prerender each locale. Most teams add a library such as next-intl on top. It works well and handles more complex cases, like locale negotiation from the Accept-Language header. For two languages on a static site, it is more machinery than the job needs.

Hosting and running costs

Astro’s static output is a folder of HTML, CSS, images and a little JavaScript. You can put it on any CDN. This site is deployed as Cloudflare Workers static assets: security headers, including a Content Security Policy, live in a plain public/_headers file, and exactly one route, /api/contact, runs Worker code for the contact form. There is no server to keep warm and no framework runtime in production.

The Cloudflare acquisition raised the obvious question about lock-in. So far the answer is reassuring: Astro 7 even shipped experimental CDN cache providers for Netlify and Vercel alongside Cloudflare. I would still keep an eye on it. Keeping the site fully static is my insurance: a folder of files can move to another host without code changes.

Next.js runs best on Vercel, which builds it. Elsewhere, the Adapter API went stable in Next.js 16.2, and OpenNext is the usual route onto Cloudflare. You can also use a static export, but you give up the features that make Next.js worth choosing, such as request-time rendering, Proxy and on-demand revalidation. If you are going to export a static Next.js site, ask yourself why you are not using a static-first framework.

Developer experience

Astro’s .astro files are HTML with a frontmatter script on top. Anyone who knows HTML and a bit of JavaScript can edit a page. You can drop in React, Svelte or Vue components where you need them, which is handy when you already have a React component library (I reviewed the one I use most in my shadcn/ui review).

The cost is two mental models. Astro components run once on the server. Islands are real React components that hydrate in the browser. Props passed to an island have to be serialisable, so you cannot pass a function from an Astro page into a React island. You learn that boundary in a day, but you do have to learn it.

Next.js gives you one model: React everywhere, with 'use client' marking the boundary. The ecosystem is enormous, and almost every React library has a Next.js example. The downside is churn in the caching story. Over recent releases the App Router moved from implicit caching to Cache Components with 'use cache'. The new model is clearer, but tutorials from a year ago may now mislead you.

When Next.js wins

I do not want this to read as “Astro good, Next.js bad”. There are sites where I would pick Next.js without thinking.

When the site is an app. The exam platform I built at PT Artristik Studio is the clear case. Candidates logged in, sessions mattered, and the browser ran TensorFlow.js and MediaPipe for proctoring. Nothing about it was a document. Next.js gave me routing, server code, data fetching and React state in one place.

When auth and per-user data are everywhere. If most pages depend on who is logged in, you want a framework that renders per request by design. Server Actions for mutations and layouts that hold state across navigations are real advantages here.

When pages mix static and personal content heavily. Cache Components let one response stream a prerendered shell with request-time parts, such as a user avatar next to a cached article. Astro’s server islands (server:defer, which needs an adapter) cover the small version of this, like a cart count or a “logged in as” badge. Once half the page is personal, Next.js is the more natural fit.

When the team already lives in Next.js. A product team with a Next.js app and a shared component library should usually build the marketing site in the same repo, on the same framework. One deploy pipeline beats a few kilobytes.

Pick the framework that matches the shape of the thing, not the one that wins the benchmark you saw last week.

Side by side

AstroNext.js
Default JS per pageNone until you add an islandReact and the router on every App Router page
Rendering modelStatic by default, on-demand per route or server islandServer Components, with Cache Components for static and dynamic in one response
Content workflowBuilt-in content collections with Zod schemas, MDX integrationAssemble it: @next/mdx or a library, your own loader and validation
i18nBuilt-in routing configProxy plus app/[lang], usually with a library
HostingAny static host; adapters for server routesBest on Vercel; Adapter API and OpenNext elsewhere
UI frameworkAny (React, Svelte, Vue) or noneReact only
Best fitMarketing, portfolio, blog, docsApps, dashboards, auth-heavy products
Version (Nov 2026)7.416.4

Verdict: who should pick what

Pick Astro if you are building a portfolio, a landing page, a blog, docs, or a company profile for a client who will update it a few times a month. You will ship less JavaScript without trying, the content workflow is done for you, and the output runs on a free static host.

Pick Next.js if the marketing site is the front door of a React product, if most pages depend on the logged-in user, or if your team already runs Next.js and shares components across the product and the site.

If you are unsure, list your pages and mark each one “same for everyone” or “different per user”. Mostly the first: Astro. Mostly the second: Next.js. If it is a near tie, use what your team knows.

If you want to see what this looks like in practice, the stack page lists what I use day to day, and the launch checklist covers the SEO, header and analytics work this site needed before going live.

FAQ

Is Astro faster than Next.js?

For content pages, usually yes out of the box, because Astro ships no JavaScript unless you add an island. A carefully built Next.js page can also be fast. The difference is that Astro’s default is the fast path, while in Next.js you have to stay on it.

Can I use React components in Astro?

Yes. Install the React integration and use components either as static HTML (no directive) or as hydrated islands with client:load, client:idle or client:visible. This site uses React islands for its navigation and a few interactive tiles.

Does Cloudflare owning Astro lock me into Cloudflare?

Not at the time of writing (November 2026). Astro remains MIT-licensed and still supports other hosts, including Netlify and Vercel. A fully static Astro build is just files, so it is the most portable option either way.

Can Next.js build a fully static marketing site?

Yes, with a static export, or by guarding routes with the ensureStatic option added in Next.js 16.4. You give up request-time features in the export case. If everything is static, a static-first framework is usually the simpler tool.

Should I migrate my Next.js marketing site to Astro?

Only if it hurts. If the site is slow, costs real money to host, or content edits are painful, a migration pays off. If it lives next to a Next.js app and works, the shared tooling is probably worth more than the switch.

Have a project in mind?

I take on a few projects at a time. Tell me about yours.

Get in touch