Guides/Kebab-case URL slugs
Kebab case for URL slugs
URL path segments favorkebab-case: lowercase words joined with hyphens. It reads clearly in the address bar and avoids spaces or ugly %20 encodings.
Patterns
- Title “Tip Before or After Tax?” →
tip-before-or-after-tax - Prefer hyphens over underscores in public URLs —snake vs kebab.
- Code identifiers may still usecamel / Pascal / snake.
Practical rules
- Lowercase; strip most punctuation.
- Join words with single hyphens; collapse repeats.
- Keep slugs stable after publish — changing them breaks links.
Headlines vs slugs
Display titles can use Title Case; slugs stay kebab —title vs sentence·headline title case·ALL CAPS cleanup.