Newsletter
Join the Community
Subscribe to our newsletter for the latest news and updates
An open-source Astro 6 starter theme for markdown content sites, styled with Tailwind CSS v4 and DaisyUI v5, with built-in search, RSS, and SEO.
StarGarden is an MIT-licensed Astro 6 starter theme for building markdown-powered content sites, styled with Tailwind CSS v4 and DaisyUI v5. It's maintained by GitHub user sustanza, installable through Astro's official starter command, and has a live demo at stargarden.pages.dev.
StarGarden is a boilerplate theme that takes Markdown files from src/content/posts and src/content/pages and compiles them into a static Astro site. It ships with a landing page, a blog index and post pages, legal pages (about, privacy, TOS, FAQ), a 404 page, an RSS feed, a sitemap, and a dynamic robots.txt. The template uses Astro 6 content collections with schemas defined in src/content.config.ts and image optimization through astro:assets.
src/content.config.ts, with Markdown and cover images co-located in src/content/posts/.prefers-color-scheme on first visit and persisting the user's toggle in localStorage.<ClientRouter /> for SPA-style navigation and hover-strategy prefetching to speed up clicks.BaseHead.astro emits OpenGraph, Twitter Card, canonical, and JSON-LD Organization markup on every page.sitemap.xml and dynamic robots.txt follow the site: URL in astro.config.mjs; the RSS feed at /rss.xml includes full post HTML and cover-image enclosures.data-theme, plus reading-time estimates and clickable heading anchors on every post.src/consts.ts, astro.config.mjs, src/components/Footer.astro, public/favicon.svg, and demo content./rss.xml, and indexes posts with Pagefind at build time.src/content/pages/ and can be edited or extended using the same <slug>/index.md pattern.src/content/pages/, and readers get Pagefind search plus syntax-highlighted code blocks that follow the active light or dark theme.Two install paths are supplied: npm create astro@latest -- --template sustanza/stargarden or git clone https://github.com/sustanza/stargarden.git. After npm install, npm run dev starts the Astro dev server on http://localhost:4321/. Content is authored as Markdown in the src/content/ collections, then npm run build produces dist/ including the Pagefind search index.
StarGarden is free and open source under the MIT License.
Yes. The project is released under the MIT License, which permits free use, modification, and redistribution, including for commercial projects.
Pagefind indexes built HTML, not source Markdown. The search input renders under npm run dev, but no results appear until you have run a production build at least once. Use npm run preview:search, which builds and previews in one step, to test search locally.
The template builds to dist/404.html. Hosts such as Cloudflare Pages, Netlify, and Vercel serve this file automatically with a 404 status code; self-hosted nginx or other static servers may need explicit configuration to return the right status.
The cover image enclosure uses absolute URLs and resolves correctly in feed readers. However, inline Markdown images in post bodies use local relative paths and will not resolve in subscribers' readers; host body images in public/ with absolute paths or reference them by full https:// URL if you need them in the feed.
