BetterLink Logo BetterLink Blog
Switch Language
Toggle Theme

What is Astro? Understanding Zero JS, Islands Architecture, and Content-First in 3 Minutes

Astro Islands Architecture diagram - interactive islands in a static HTML ocean

A while back, I built a tech blog with Next.js. After bundling, I was shocked to see the JavaScript size hit 500KB. I was confused—this was just a site for displaying articles, mostly text and images. Why did it need to load so much JS?

I opened Chrome DevTools and felt even worse: 3-second load time and tons of “unused JavaScript” warnings. It made me wonder: is using React/Vue for content sites like using a sledgehammer to crack a nut?

Then I discovered Astro. Its philosophy is simple—most websites don’t need that much JavaScript. Sounds radical, right? But after seeing its architecture, I realized this idea actually makes a lot of sense.

After reading this article, you’ll understand Astro’s three core concepts (content-first, zero JS by default, Islands Architecture), how it fundamentally differs from frameworks like Next.js and React, and when you should (or shouldn’t) choose Astro. No fluff, just straight talk.

Why Traditional Frameworks Are “Heavy”—Why Does Your Static Site Need 500KB of JavaScript?

Let’s talk about how traditional SPAs (Single Page Applications) work, so you can understand why they’re so “heavy.”

Take React as an example. When you visit a React website, the browser first loads the entire React runtime (about 130KB), then loads your business code, and finally performs “hydration”—turning server-rendered static HTML into interactive components. Sounds reasonable, right?

But here’s the problem: if your page just displays a blog post with 90% text and images that don’t need interaction, why load so much JS?

I saw some shocking data: in traditional SPA frameworks, about 60% of the average 500KB of JS code goes unused. You spent 3 seconds loading code that’s mostly just sitting there.

This is the core contradiction—content display sites vs. highly interactive apps have completely different needs. An online document editor needs lots of JS for real-time collaboration, no problem. But does a product introduction page really need such a heavy framework?

Astro saw this problem and proposed a bold idea: let’s just not load JS by default.

Astro Core Concept 1: Content-First

“Content-first” doesn’t mean “write more content,” but rather an architectural philosophy—the website’s core is content display, not complex application logic.

Simply put, Astro divides websites into two categories:

  • Content display: blogs, documentation sites, corporate websites, product pages, e-commerce product details
  • Application: online collaboration tools, admin dashboards, real-time chat, complex forms

Astro’s positioning is clear: it’s built for the first category. You might think, “But can’t Next.js also do blogs?” Sure it can, but it’s like driving a tank to the grocery store—a bit wasteful.

Here’s a real case. CITIC Bank built a financial-grade metadata platform with Astro. After migrating from Next.js, they slashed JS code size by 90% and improved page performance by 30%. This isn’t hearsay, it’s an actual case.

Astro’s logic is: if your website mainly displays content (text, images, videos), most pages should be static HTML for fast loading and SEO friendliness. Only areas that truly need interaction (like comment sections, search boxes) load the necessary JS.

This is the real meaning of “content-first”—let architecture serve content, not force content to adapt to the framework.

Astro Core Concept 2: Zero JavaScript by Default

When I first heard “zero JS by default,” I was also confused: “Can it still be called a modern framework without JS?” Later I figured out it means not sending JS to the client by default, but you can add it on demand.

How do traditional SSG/SSR frameworks (like Next.js) work? They first render HTML on the server, then send the entire React framework and your component code to the browser for full hydration. Even if the page just displays text, the React runtime still has to load.

Astro’s approach is the complete opposite: generate pure static HTML first, with no JS by default. For areas that need interaction, you manually mark “this component needs JS.”

Let me show you some comparison data, pretty intuitive. For the same documentation site, Next.js bundles about 150KB of JS minimum, while Astro? Maybe just 11KB, or even less. Lighthouse performance score can hit 99.

Someone might ask: “What if I want to add an image carousel?” Simple, just add a marker to that component telling Astro “this needs JS.” Everything else stays static, no impact.

This is the essence of “zero JS by default”—not that you can’t use JS, but only use it where you really need it. If your page has 10 modules and 9 are static, then only 1 module loads JS. Clean.

Astro Core Concept 3: Islands Architecture

“Islands Architecture” sounds mysterious, but the concept is straightforward. Think of it this way:

Imagine a static HTML ocean with a few interactive “islands” floating on it.

The ocean part (static content) loads super fast, no JS needed. The island parts (interactive components) independently load their own JS without interfering with each other. That’s Astro’s Islands Architecture.

This concept was first proposed by Katie Sylor-Miller, Etsy’s frontend architect, in 2019, then popularized by Jason Miller, Preact’s creator. Astro was the first framework to truly use this architecture in production.

Technically, it uses “partial hydration.” Traditional frameworks do full hydration—the entire page’s virtual DOM must be rebuilt. Astro? Only hydrates components marked as “needs interaction.”

For example, your blog post page has these parts:

  • Article title and body (static)
  • Table of contents navigation (static)
  • Comments section (needs interaction)
  • Share button (needs interaction)

Traditional frameworks would hydrate the entire page. Astro only hydrates the comments section and share button. The result? TTI (Time to Interactive) can drop by 300%.

Even cooler, Astro provides “hydration directives” that let you precisely control when to load JS:

  • client:load - load immediately after page load (for critical interactions)
  • client:idle - load when browser is idle (for non-urgent features)
  • client:visible - load when scrolled into view (image carousels, video players)

Each island is independently rendered and doesn’t block others. If your comments section loads slowly, it doesn’t affect the share button’s normal operation. This is especially useful when multiple components load in parallel.

Simply put, Islands Architecture takes the concept of “load on demand” to the extreme.

Core Differences with Traditional Frameworks: Three Website Building Philosophies

Now you should roughly understand Astro’s approach. But you might still be thinking: “How exactly is it different from React and Next.js? Which should I choose?”

Let’s look at it from another angle. These frameworks represent three completely different website building philosophies:

1. Pure React/Vue/Svelte - Heavy Client Philosophy

The core idea is to treat the browser as an application runtime environment, pursuing the ultimate interactive experience.

  • Characteristics: All logic runs on the client, large JS size, but smooth interaction
  • Suitable scenarios: SaaS backends, online drawing tools, document editors, complex forms
  • Typical representatives: Figma, Notion, Google Docs

If you’re building a web app that needs frequent interaction, this approach is fine.

2. Next.js/Nuxt - Full-Stack Platform Philosophy

Wants both SPA’s interactive capabilities and SSR/SSG’s performance and SEO. They’re not just frontend frameworks, they let you write backend APIs, aiming to be a “full-stack development platform.”

  • Characteristics: Server-side rendering + client hydration, full-featured but larger
  • Suitable scenarios: Complex e-commerce, social apps, frequently updated data websites
  • Typical representatives: Netflix, TikTok, Hulu

If your project needs complex user interaction + server-side logic, Next.js is a good choice.

3. Astro - Content-First Philosophy

The core is “static HTML by default + on-demand JS,” specifically optimized for content display websites.

  • Characteristics: Extremely small JS size (83-90% reduction), maxed performance, SEO friendly
  • Suitable scenarios: Blogs, documentation sites, corporate websites, marketing pages, e-commerce product displays
  • Typical representatives: Tech blogs, corporate websites, online documentation

If you’re building a content site, Astro is a game changer.

Here’s a comparison table for clarity:

FeatureAstroNext.jsPure React
JS SizeTiny (11KB+)Larger (150KB+)Large (130KB+)
Learning CurveLow (similar to JSX)Medium (need to learn SSR concepts)Low
Framework BindingNone (supports React/Vue/Svelte)React onlyReact only
Use CasesContent displayFull-stack appsComplex interaction
SEOExcellent (static HTML)Good (SSR)Poor (needs extra config)
Initial LoadFastestFastSlower

Key insight: Astro is “framework agnostic.” You can use React, Vue, Svelte components, even mix them in one project. It’s not trying to replace React, but gives you the option to “only use React when you need it.”

What Is Astro Good For? What Isn’t It Good For?

After all this, when should you actually use Astro? I’ll give you a checklist for quick judgment.

✅ Good Use Cases for Astro:

  1. Personal Blogs, Technical Documentation

    • Mainly text and images
    • Little interaction (just comments, search boxes, etc.)
    • Needs SEO optimization
    • Example: Most tech blogs you’re reading now
  2. Corporate Websites, Marketing Landing Pages

    • Display products and services
    • Needs fast loading (load speed affects conversion)
    • Relatively fixed content
    • Example: SaaS product websites, promotional pages
  3. E-commerce Product Display Pages

    • Note: “display pages,” not shopping carts and checkout flows
    • Lots of product images and descriptions
    • Needs SEO (search engine indexing products)
    • Example: Product detail pages, category pages
  4. Portfolio Websites, Personal Homepages

    • Display your projects and skills
    • Simple and fast
    • Easy to maintain
    • Example: Designer portfolios, developer personal sites

❌ Not Good Use Cases for Astro:

  1. Highly Interactive Web Apps

    • Online collaboration tools (like Figma, Miro)
    • Complex dashboards (real-time data refresh)
    • Admin backends (lots of forms and operations)
    • In these scenarios, the entire page needs JS, so Astro is overkill
  2. Apps Needing Real-Time Data Updates

    • Chat apps
    • Stock trading platforms
    • Real-time collaborative docs
    • Astro mainly generates static pages, not good at handling real-time data
  3. Pure Single Page Applications (SPAs)

    • If your website is a complex app that doesn’t need SEO
    • Just use React/Vue directly, Astro can’t help

A Simple Decision Standard:

Ask yourself two questions:

  1. Is my website mainly displaying content, or providing complex interactions?
  2. If JavaScript is completely disabled, can the website still be viewed?

If the answer is “display content” + “can view,” then Astro is probably right for you. If it’s “complex interaction” + “can’t view,” then consider Next.js or pure SPA frameworks.

How Beginner-Friendly Is It? High Learning Curve?

You might be worried: “Another new framework to learn from scratch?” Good news is, Astro’s learning curve is really friendly.

Super Familiar Syntax

.astro file syntax is almost identical to JSX and Vue. If you’ve written React or Vue, you can pick it up at a glance. Some people even say “the learning curve is almost ridiculously low.”

Plus, you don’t have to use .astro syntax. You can directly use .md (Markdown), .jsx (React), .vue (Vue) to write content. Use whichever you want, even mix them in one project.

Ready-to-Use Themes

Astro has a theme marketplace full of ready-made blog templates, documentation site templates, portfolio templates. Find one you like, change the text and colors, and you can go live in half an hour. Really “just tweak Markdown to build a beautiful website.”

Smooth Development Experience

Built on Vite and Esbuild, startup speed is blazing fast. Hot updates are also quick, you see effects immediately after changing code. This is super important for developers.

Well-Developed Documentation and Community

Astro’s official documentation is very clear, teaching you step by step how to get started. The community also has plenty of tutorials and videos. You can basically find answers to any problems.

Honestly, if you just want to build a blog or documentation site, Astro might be the fastest choice. No need to configure complex build tools, no need to fuss over routing, it works out of the box.

Conclusion

After all that, let’s recap Astro’s three core concepts:

  1. Content-First: Designed specifically for content display websites, letting architecture serve content
  2. Zero JS by Default: Don’t send JavaScript by default, only load it where truly needed on demand
  3. Islands Architecture: Interactive islands in a static HTML ocean, independently hydrated without blocking each other

Its core difference from traditional frameworks is—modern framework development experience with static website performance. You get component architecture, hot updates, TypeScript support and other modern features, while achieving loading speeds close to pure HTML.

If you’re building a blog, documentation site, corporate website, or marketing page, really give Astro a try. It’s not a silver bullet, but in its sweet spot, it’s truly a game changer.

One last reminder: Astro doesn’t mean “can’t use JS,” but “don’t use JS by default.” Where you need interaction, use it, just won’t shove the entire runtime at you like traditional frameworks.

To get started, just go to the Astro website and check the docs. Browse the theme marketplace too, you might find a template you like. Don’t overthink it, just give it a try.

Published on: Dec 2, 2025 · Modified on: Dec 4, 2025

Related Posts