Skip to content
New: Customize your theme with an AI assistant. Read the guide

Installation Guide

Skill level: Beginner · Time: 10 minutes

You need two things on your computer: Node.js (the program that runs the theme) and a code editor to open the files. If you have never used a terminal before, read Tools You Need first.

Requirements

  • Node.js 22.23.4 or later (engines in package.json, the same in all three editions). The Tina edition’s README adds a limit: Node.js 22 (22.23.4 or later) or 24, the only two versions Tina’s command line tool supports
  • npm, which comes with Node.js. Ecozen ships a package-lock.json, so use npm rather than Yarn or pnpm
  • A code editor. VS Code is a good free choice; Ecozen recommends its Astro, TOML, and Tailwind CSS extensions when you open the folder

Install Node.js

Download the LTS installer from nodejs.org and run it. Then open PowerShell and check the version:

Terminal window
node -v

The result must be v22.23.4 or higher.

These steps are the same in all three editions. In the Tina edition, npm run dev also starts the editor at /admin/: see Tina. In the Sanity edition, the site runs with bundled demo content until you run npm run setup: see Sanity.

Run Ecozen On Your Computer

  1. Unzip the download and move the theme folder to wherever you keep your projects. Open it in your code editor. It is the folder that contains package.json and AGENTS.md.

  2. Open a terminal inside that folder. In VS Code, use Terminal → New Terminal.

  3. Install the dependencies (only needed once, and again after updates):

    Terminal window
    npm ci

    npm ci installs the exact versions listed in package-lock.json. npm install works too.

  4. Start the development server:

    Terminal window
    npm run dev
  5. Open http://localhost:4321/ in your browser.

Leave the terminal running while you work. When you save a file, including src/config/config.toml, the browser updates on its own. Press Ctrl + C in the terminal to stop the server.

Build And Preview The Production Site

Terminal window
npm run build
npm run preview

npm run build writes the finished site to the dist/ folder. npm run preview builds it again and serves it at http://localhost:4321/, so you can test it exactly as visitors will see it.

Until you set your own address in config.toml, the build prints a yellow [site] warning when the Astro step finishes: the theme ships with the placeholder https://example.com. That is expected on your computer; set the address before you deploy (Quick Start, step 1).

Every Script, In Plain Words

CommandWhat it does
npm run devStarts the local site with live reload
npm run buildBuilds the production site into dist/ and removes drafts from the sitemap. Warns while the site URL is still https://example.com
npm run previewBuilds, then serves the production site locally
npm run astro-checkChecks components and the content files that have a schema for mistakes. It doesn’t check section, about, contact, FAQ, pricing, or calculator files. Run it before you deploy
npm run formatTidies the formatting of files in src/
npm run generate-faviconsCreates every favicon size from [site.favicon] image in config.toml
npm run remove-multilingualDeletes every language except the default one. Read Internationalization first
npm run generate-multilingual-contentAdds a language as a copy of the default one. It needs flags such as --lang, and it keeps files you already translated: see Internationalization
npm run remove-draft-from-sitemapRemoves draft pages from the built sitemap. build already runs it
npm run deploy:cfUploads dist/ to Cloudflare Pages. Needs Wrangler installed first (see Deployment)
npm run toml:watchTurns config.toml into .astro/config.generated.json. dev, build, and astro-check already run it
npm run test, npm run test:watchRuns the theme’s unit tests once, or again on every change. You don’t need them to edit the site

The Tina and Sanity editions add their own commands, such as npm run tina:audit and npm run dev:all. Their READMEs and the Tina and Sanity pages list them.

Next: Quick Start, to make the site yours in about 30 minutes.

Type something to search...