# Reserved slugs

> A slug format and length check and a list of reserved words (admin, api, www, ...), enforced by a trigger.

- Category: Tenancy & accounts
- Module: `reserved-slugs`
- Modes: `managed`
- Docs: https://bettersupabase.com/docs/blocks/reserved-slugs
- Page: https://bettersupabase.com/blocks/reserved-slugs

## Install

```bash
npx better-supabase add reserved-slugs
```

## Configure

Add the block to `better-supabase.config.ts`:

```ts
import { defineConfig } from "better-supabase/config";

export default defineConfig({
  blocks: {
    // Modes: "managed". The default is "managed".
    "reserved-slugs": { mode: "managed" },
  },
});
```

## Client

The block is SQL only: call its functions from your policies, RPCs and the other modules.

## Recipes

- [Workspace URL field](https://bettersupabase.com/recipes/workspace-url-field.md): An organization form with a name and a URL slug, where reserved and taken slugs come back as field errors.
