# Route segments

URL: /code/file-conventions/route-segments · Id: `page:code/file-conventions/route-segments`

> The folder names in a Site set its URLs, with groups, keys, private folders and Experiment Variants.

The folder names in a [Site](/business/nouns/site) set its URLs. A folder is a segment, and four spellings change what a segment does.

```text
sites/www/
├── (legal)/security/page.mdx     /security
├── blog/[post]/page.mdx          /blog/:post, one Page per member
├── _drafts/hero.mdx              private, never served
└── pricing/@annual/page.mdx      an Experiment Variant of /pricing
```

## Reference
| Name | URL | Does |
| --- | --- | --- |
| `name/` | `/name` | A segment |
| `(group)/` | none | Groups folders, often under a shared layout, and adds no segment |
| `[key]/` | `/:key` | One [Page](/business/nouns/page) per member of the [Collection](/business/nouns/collection) the Page is `about` |
| `_name/` | none | Private: never served, never published |
| `@arm/` | the parent's | A [Variant](/business/nouns/variant) of the parent Page in an [Experiment](/business/nouns/experiment) |

## Examples
### Minimal
```mdx title="sites/www/blog/[post]/page.mdx"
---
about: content/blog
---
<Article />
```

### Leaseline
`blog/[post]/page.mdx` serves one Page per published post, and `pricing/@annual/page.mdx` tests annual billing first.

```mdx title="sites/www/pricing/@annual/page.mdx"
---
title: Pricing
---
<PriceTable offers={["pro-annual", "pro"]} />
```

## What it builds
The [SiteBuilder](/code/builders/site) resolves the tree into Pages.

- a `Page` per member under `[key]/`, added and removed as the Collection changes
- an `Experiment` with one Variant per `@arm/`, started with `Experiment.start`
- the losing arm goes dormant when `Experiment.conclude` picks a winner

## Good to know
- Keys come from the Collection; a slug equal to a declared [Verb](/business/nouns/verb) is refused.
- [Routing](/code/routing) has every URL rule.