Astro builds a static site by default: every page becomes an HTML file in dist/, with only the JavaScript your islands need. That folder is all Lobsite needs. Run npm run build, then npx lobsite in the project, and the site is live at a *.lobsite.app address with HTTPS. You can also drop dist/ in the box above.
How it works
- Build the site with
npm run build(that'sastro build). The pages, images and scripts land indist/. - Run
npx lobsitein the project. It deploysdist/, notpublic/, which Astro has already copied into the build. The first deploy needs no account and lasts 6 hours. - Keep it with the claim link, in a free account. The folder is saved in
lobsite.toml, so the next build deploys with the samenpx lobsite.
Settings worth checking in astro.config.mjs
import { defineConfig } from "astro/config";
export default defineConfig({
site: "https://my-site.lobsite.app",
trailingSlash: "ignore",
});
siteis your full address. Astro uses it for canonical URLs,Astro.site, and the sitemap from@astrojs/sitemap. Set it to your*.lobsite.appaddress, and change it when you move to your own domain.basestays unset: the site is served from the top of its address, not a subfolder as on a GitHub Pages project site.build.formatcan stay at its default.about/index.htmlopens at/about/, and anabout.htmlfile opens at/about.
What works, and what needs a server
Everything Astro renders at build time works: content collections, Markdown and MDX, astro:assets images (optimised during the build), and islands from React, Vue, Svelte or Solid, which run in the browser. Anything that runs per request doesn't: pages with export const prerender = false, output: "server", Astro Actions and API endpoints that aren't prerendered. Those need a server adapter, and Lobsite only serves files. For a contact form, point it at /_lobsite/forms/contact instead of an Astro Action; see forms.
Files are stored by their hash. Redeploying an unchanged site uploads 0 bytes.
Preview before going live. Roll back in one click, redirects and all.
Every site gets a *.lobsite.app address with HTTPS from the first deploy.
Point a form at /_lobsite/forms/contact. Spam filtering included.
Redirects, headers and forms live in lobsite.toml and travel with each deploy.
A deploy without an account is live for 6 hours. The claim link keeps it, free.
Astro hosts compared
| Lobsite | Netlify | Vercel | GitHub Pages | |
|---|---|---|---|---|
| Static Astro sites | Yes | Yes | Yes | Yes, with Astro's GitHub Action |
| Server rendering (adapter) | No | Yes | Yes | No |
| Builds on the server | No: you deploy dist/ |
Yes | Yes | In GitHub Actions |
| Account before the first deploy | No: live 6 hours, then keep it free | Yes | Yes | Yes, and a repository |
| Forms without a backend | Yes, once the site is in an account | Yes | No | No |
| Custom domain | Yes, free | Yes | Yes | Yes |
If parts of your site render on request, choose a host with an Astro adapter. If the site is static, which is Astro's default, Lobsite deploys it in seconds from your machine, CI or an AI agent, and only the files a build changed are uploaded.
Frequently asked questions
Do I need an adapter to host Astro on Lobsite?
No. Adapters are for server rendering. A static Astro site, the default, needs no adapter: deploy the dist/ folder.
Why does npx lobsite deploy dist/ and not public/?
In an Astro project, public/ holds files the build copies as they are, such as favicon.svg. The built site is dist/. Lobsite sees astro in package.json and skips public/ for you.
Can I add a custom 404 page to my Astro site?
Yes. Create src/pages/404.astro; Astro builds it as 404.html, and Lobsite serves it with a 404 status for any address that doesn't exist.
Does Astro's image optimisation work?
Yes. astro:assets resizes and converts images during astro build, so the optimised files are already in dist/ when you deploy. Only on-demand image services that run per request need a server.