Free Astro tutorials for complete beginners.

Beginner's Guide to Astro

Lesson 1 of 7, about 25 minutes

Your toolkit: the five things you need

One checklist of the five tools every Astro site uses, a plain picture of how they fit together, and the steps to set each one up. No experience needed.

Tested on Astro 7.4

Every website built with Astro uses the same five tools. Here they are in one list. Below the list, you’ll see how they fit together. Then we set them up, one at a time.

The checklist

Tool What it does Cost
1 An AI helper. We use Claude Code. Writes code with you and fixes errors Free chats exist. Claude Code needs a plan.
2 Node.js The engine that runs Astro on your computer Free
3 VS Code Where you see and change your files Free
4 GitHub Keeps a safe copy of your project online Free
5 A host. Our picks are Spacefast and Cloudflare. Puts your site on the internet Free plans

Tick them off as you go. Only number 1 is optional. Every lesson shows you the exact lines to type, so you can do the whole course with no AI at all.

How the five fit together

  1. You + AIwrite the files
  2. Your computerbuilds the site
  3. GitHubkeeps a copy
  4. Your hostputs it online
  5. The worldsees your site
  1. You and your AI helper write the files. You say what you want. It writes the code. Or you type the code yourself, from these lessons.
  2. Your computer turns the files into a website. That’s Astro’s job, and Node.js is what runs Astro. You can see the site on your own screen before anyone else does.
  3. GitHub keeps a copy. Every change you send it is saved, so you can always go back.
  4. Your host puts it online. It watches GitHub. When you send a change, it updates your live site by itself, in about a minute.

That’s the whole process. Write, build, save, publish. Every lesson after this one is one of those steps.

Step 1: Get your AI helper

Claude Code is the one we use to build this site. It runs in your terminal and works inside your project. To install it on a Mac, open Terminal (press Command and Space, type Terminal, press Enter) and paste this line:

curl -fsSL https://claude.ai/install.sh | bash

It needs a Claude plan to run. The free way is a chat: open claude.ai and paste code in yourself. Both ways are in our guide to building an Astro site with Claude.

Step 2: Install Node.js

Node.js is the engine that runs Astro’s tools. Your visitors will never need it. Your computer does, while you work.

On a Mac, use Homebrew. It’s a tool that installs other tools, and it keeps them up to date. In Terminal, paste this line and press Enter:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

It asks for your Mac password. You won’t see the letters as you type. That’s normal. Press Enter. It takes a few minutes.

Now install Node.js:

brew install node

On Windows, go to nodejs.org, click the big button that says LTS, open the file it downloads, and click Next until it finishes. LTS means “the steady version”.

Astro needs Node.js version 22.23.4 or newer, and an even number, like 22, 24 or 26. Both ways above give you one that works.

Step 3: Install VS Code

VS Code is the program you’ll write in. It’s free, from Microsoft.

  1. Go to code.visualstudio.com.
  2. Click the download button and install it.
  3. Open VS Code. On the left edge, click the icon that looks like four squares. That’s the Extensions panel.
  4. In the search box, type Astro. Click Install on the one by “astro.build”.

That extension colours your code and spots typos for you.

Now check that Node.js is there. At the top of VS Code, click the Terminal menu, then New Terminal. A panel opens at the bottom. Click inside it, type this, and press Enter:

node -v
Terminal
$ node -v
v24.21.0

Step 4: Make a GitHub account

Git is the tool that tracks changes to your files. GitHub is the website that keeps a copy of them online.

  1. Go to github.com and click Sign up. It’s free. Pick a username you’d be happy to show people, because it ends up in your site’s address if you use GitHub Pages.
  2. Check that Git is on your computer. In the VS Code terminal, type git -v and press Enter. On a Mac, Homebrew already installed it. On Windows, if it says “not recognized”, get it from git-scm.com and click Next until it finishes.

You won’t use GitHub until lesson 7. Making the account now means nothing stops you then.

Step 5: Pick a host

A host is a company with computers that stay on all day, so your site is always there. You only need one. All of these have a free plan, and all of them work with Astro.

Host Why pick it
Spacefast Our pick for most sites. Drag your site’s folder onto a web page, or run one command. No account for the first try. Made by the company behind WordPress.com.
Cloudflare Our pick for EmDash. What we use for this site. Free with no visitor limit. Our guide.
Netlify Also drag-and-drop. Lesson 7 shows it step by step.
Vercel Free for personal sites. Business sites need a paid plan.
GitHub Pages Free with the account you just made. Our guide.

Can’t decide? Use Spacefast. Lesson 7 shows how. You can switch later. Our hosting guide compares them properly.

You don’t need to make the account yet. Lesson 7 walks you through it.

What you just did

You have the whole toolkit. An engine, a place to write, a safe copy, a host, and a helper. That’s everything a professional has.

Finished lesson 1?

Mark it done to light its star, and we'll take you straight to lesson 2.

Try "blog", "deploy" or "EmDash".