To build a salon website with Astro, put your services in a content collection with prices and durations, give each stylist a profile page, show your work in an optimized image gallery, send the Book button to your salon booking software, and add HairSalon or BeautySalon structured data for local search. An Astro salon website is static, so it loads quickly on the phones most clients use to book, and it has no plugins or database to maintain.
This guide walks through the pages a salon site needs, the Astro 7 code for each, and the details that turn a visit into a booking.
Key Takeaways
- Clients want to see services, prices, who’ll do their hair and the next free slot. Make the Book button reachable from every page.
- Store the service menu as structured data so prices and durations stay consistent across pages.
- Link to your existing booking system rather than building appointments into the website.
- A gallery sells more than copy. Use
astro:assetsso dozens of photos don’t slow the page.- Add
HairSalonorBeautySalonJSON-LD and keep it identical to your Google Business Profile.
What clients look for on a salon website
People visiting a salon site are usually close to booking. They want to confirm a few facts quickly.
| Page | What it must answer |
|---|---|
| Home | Salon style, location, hours, a clear Book button |
| Services | Every service with price (or “from” price) and duration |
| Stylists | Who works there, their specialties, their work |
| Gallery | Real cuts, colors and treatments from your salon |
| Book | Your booking system, plus a phone number |
| Visit | Address, parking, opening hours, cancellation policy |
| Gift cards | A link to buy them if your booking software sells them |
Keep the phone number as a tel: link in the mobile header. Plenty of clients still prefer to call, especially for color consultations.
Create the project
# Terminal
npm create astro@latest salon-site
cd salon-site
npx astro add sitemap
npm run dev
To start from a finished design, the Astro hair and beauty themes category has 29 themes at the time of writing. Avlon is designed for beauty salons, and Bear Barber includes team, locations and service pages built on Astro content collections. If you’d rather begin with a free base, Astro’s official starters or a general business template like AstroWind can be adapted, though the service menu and stylist pages will be yours to build.
Model the service menu and stylists
A salon menu has categories (cuts, color, treatments), and each service has a price and a duration. One JSON file per menu keeps editing simple.
// src/content.config.ts
import { defineCollection, reference } from 'astro:content';
import { glob, file } from 'astro/loaders';
import { z } from 'astro/zod';
const stylists = defineCollection({
loader: glob({ pattern: '**/*.md', base: './src/content/stylists' }),
schema: ({ image }) =>
z.object({
name: z.string(),
level: z.enum(['Stylist', 'Senior stylist', 'Creative director', 'Colorist']),
specialties: z.array(z.string()),
photo: image(),
photoAlt: z.string(),
bookingUrl: z.url().optional(),
}),
});
const services = defineCollection({
loader: file('src/data/services.json'),
schema: z.object({
name: z.string(),
category: z.enum(['Cuts', 'Color', 'Treatments', 'Styling']),
priceFrom: z.number(),
durationMinutes: z.number(),
note: z.string().optional(),
stylists: z.array(reference('stylists')).default([]),
}),
});
export const collections = { stylists, services };
// src/data/services.json
[
{ "id": "womens-cut", "name": "Cut and blow-dry", "category": "Cuts", "priceFrom": 65, "durationMinutes": 60 },
{ "id": "balayage", "name": "Balayage", "category": "Color", "priceFrom": 180, "durationMinutes": 180, "note": "Skin test required 48 hours before" }
]
Showing “from” prices with a duration is the honest middle ground for services whose final cost depends on hair length or stylist level. The content collections guide explains file() and reference() in more depth.
Render the service menu
Group services by category and show name, duration and price on one line. This is the page clients compare salons on.
---
// src/pages/services.astro
import { getCollection } from 'astro:content';
import BaseLayout from '../layouts/BaseLayout.astro';
import BookButton from '../components/BookButton.astro';
const services = await getCollection('services');
const groups = Object.groupBy(services, (s) => s.data.category);
const order = ['Cuts', 'Color', 'Treatments', 'Styling'];
---
<BaseLayout title="Services and prices" description="Our full menu of cuts, color and treatments with prices and times.">
<h1>Services and prices</h1>
{order.filter((cat) => groups[cat]).map((cat) => (
<section>
<h2>{cat}</h2>
<ul class="menu">
{groups[cat].map((s) => (
<li>
<span class="name">{s.data.name}</span>
<span class="time">{s.data.durationMinutes} min</span>
<span class="price">from ${s.data.priceFrom}</span>
{s.data.note && <small>{s.data.note}</small>}
</li>
))}
</ul>
</section>
))}
<BookButton />
</BaseLayout>
Keep the menu as real text, not an image of a printed price list. Text is readable on every screen, searchable, and quotable by search engines and AI assistants answering “how much is balayage at” questions.
Stylist profiles
Clients often book a person, not a salon. Give each stylist a page with their specialties, their work and a direct booking link if your software supports per-stylist booking.
---
// src/pages/stylists/[id].astro
import { getCollection, render } from 'astro:content';
import { Image } from 'astro:assets';
import BaseLayout from '../../layouts/BaseLayout.astro';
export async function getStaticPaths() {
const stylists = await getCollection('stylists');
return stylists.map((s) => ({ params: { id: s.id }, props: { stylist: s } }));
}
const { stylist } = Astro.props;
const { Content } = await render(stylist);
const fallback = import.meta.env.PUBLIC_BOOKING_URL ?? '/contact/';
---
<BaseLayout title={`${stylist.data.name}, ${stylist.data.level}`} description={`Book with ${stylist.data.name}: ${stylist.data.specialties.join(', ')}.`}>
<Image src={stylist.data.photo} alt={stylist.data.photoAlt} width={480} height={600} />
<h1>{stylist.data.name}</h1>
<p>{stylist.data.level}. Specializes in {stylist.data.specialties.join(', ')}.</p>
<Content />
<a class="btn" href={stylist.data.bookingUrl ?? fallback}>Book with {stylist.data.name.split(' ')[0]}</a>
</BaseLayout>
Online booking without building it yourself
Salon booking software already handles calendars, deposits, reminders and no-show policies. Link to its booking page or embed its widget on a /book/ page.
---
// src/components/BookButton.astro
const bookingUrl = import.meta.env.PUBLIC_BOOKING_URL ?? '/contact/';
---
<div class="book">
<a class="btn" href={bookingUrl} rel="noopener">Book an appointment</a>
<a href="tel:+15550104040">Or call (555) 010-4040</a>
</div>
If your provider gives you an embed script, load it only on the booking page rather than site-wide. Third-party booking widgets can be heavy, and the rest of the site doesn’t need them. The Partytown guide explains options for keeping third-party scripts off the main thread.
A fast gallery of your work
A gallery of real results is the most persuasive page on a salon site. With astro:assets, you can keep originals in the repo and let Astro produce sized, modern-format versions.
---
// src/pages/gallery.astro
import { Image } from 'astro:assets';
import BaseLayout from '../layouts/BaseLayout.astro';
const photos = import.meta.glob<{ default: ImageMetadata }>('../assets/gallery/*.{jpg,jpeg,png}', { eager: true });
---
<BaseLayout title="Gallery" description="Cuts, color and styling from our salon team.">
<h1>Our work</h1>
<div class="gallery">
{Object.entries(photos).map(([path, mod], i) => (
<Image
src={mod.default}
alt={path.split('/').pop()?.replace(/[-_]/g, ' ').replace(/\.\w+$/, '') ?? 'Salon work'}
widths={[320, 640, 960]}
sizes="(min-width: 900px) 33vw, 50vw"
loading={i < 3 ? 'eager' : 'lazy'}
/>
))}
</div>
</BaseLayout>
Name files descriptively (copper-balayage-long-hair.jpg) so the generated alt text is useful, or move alt text into a data file for full control. Get written permission from clients before posting photos of them. The image lightbox guide adds a full-screen view with minimal JavaScript.
Local SEO and salon schema
“Hair salon near me” searches are local, so consistency matters: the same name, address, phone and hours on your site, your Google Business Profile and directories. Add structured data to the home and visit pages.
---
// src/components/SalonSchema.astro
const schema = {
'@context': 'https://schema.org',
'@type': 'HairSalon',
name: 'Linden Hair Studio',
url: Astro.site?.href,
telephone: '+1-555-010-4040',
priceRange: '$$',
address: {
'@type': 'PostalAddress',
streetAddress: '12 Linden Avenue',
addressLocality: 'Austin',
addressRegion: 'TX',
postalCode: '78701',
addressCountry: 'US',
},
openingHoursSpecification: [
{ '@type': 'OpeningHoursSpecification', dayOfWeek: ['Tuesday', 'Wednesday', 'Thursday', 'Friday'], opens: '09:00', closes: '19:00' },
{ '@type': 'OpeningHoursSpecification', dayOfWeek: 'Saturday', opens: '08:00', closes: '16:00' },
],
};
---
<script type="application/ld+json" set:html={JSON.stringify(schema)} />
Use BeautySalon, NailSalon or DaySpa from schema.org if they describe you better. For reviews, link to your Google or booking-platform reviews rather than copying them onto your site. The JSON-LD guide covers generating schema from your data.
Deploy and keep it current
Run npm run build and deploy dist/ to Cloudflare Pages, Netlify or Vercel; our static deployment docs walk through each. Updating a price is a one-line change in services.json, and a new stylist is one Markdown file and a photo. Review the menu whenever prices change, and update holiday hours before every holiday season. The official Astro images guide covers every option the gallery uses.
FAQ
Is Astro a good choice for a salon website?
Yes. A salon site is mostly a service menu, stylist profiles, a gallery and a booking link, which Astro builds into fast static pages. Clients on phones get quick loads, and there are no plugins or database to keep updated.
How do I add online booking to an Astro salon website?
Link your Book buttons to the online booking page from your salon software, or embed its booking widget on a dedicated booking page. The software handles calendars, deposits and reminders while your Astro site stays static.
Should a salon website show prices?
Showing prices, or at least “from” prices with durations, helps clients choose and reduces back-and-forth by phone. For services that depend on hair length or stylist level, explain what changes the final price.
What schema markup should a hair salon use?
Use the schema.org HairSalon type, or BeautySalon, NailSalon or DaySpa where they fit better, with name, address, phone, opening hours and price range. Keep the details identical to your Google Business Profile.
How do I keep a photo gallery fast in Astro?
Store photos in src/assets/ and render them with the <Image /> component from astro:assets, using widths and sizes so phones get small files. Lazy-load everything below the first few images.