# Tables

> Add tables with standard Markdown syntax. Align columns and use inline formatting in cells.

Tables use plain Markdown, so they read well in the source too. No component needed.

| Method | Endpoint | Description |
|--------|----------|-------------|
| `GET` | `/users` | List users |
| `POST` | `/users` | Create a user |
| `GET` | `/users/{id}` | Get one user |
| `DELETE` | `/users/{id}` | Delete a user |

```mdx
| Method | Endpoint | Description |
|--------|----------|-------------|
| `GET` | `/users` | List users |
| `POST` | `/users` | Create a user |
| `GET` | `/users/{id}` | Get one user |
| `DELETE` | `/users/{id}` | Delete a user |
```

The first row is the header. The second row of dashes separates it from the body, and every row after that is data.

## Column alignment

Add colons to the separator row to align a column.

| Region | Servers | Uptime |
|:-------|:-------:|-------:|
| Europe | 12 | 99.98% |
| US East | 8 | 99.95% |

```mdx
| Region | Servers | Uptime |
|:-------|:-------:|-------:|
| Europe | 12 | 99.98% |
| US East | 8 | 99.95% |
```

| Separator | Alignment |
|-----------|-----------|
| `:---` or `---` | Left |
| `:---:` | Center |
| `---:` | Right |

## Formatting in cells

Cells take inline Markdown: bold, italics, inline code, and links.

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | `string` | **Yes** | Display name |
| `email` | `string` | **Yes** | A valid email address |
| `role` | `string` | No | One of `admin`, `editor`, or `viewer`. Defaults to `viewer`. |
| `notify` | `boolean` | No | Send a welcome email. See [Callouts](https://docs.typemark.dev/components/callouts) for how to flag side effects. |

```mdx
| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | `string` | **Yes** | Display name |
| `email` | `string` | **Yes** | A valid email address |
| `role` | `string` | No | One of `admin`, `editor`, or `viewer`. Defaults to `viewer`. |
| `notify` | `boolean` | No | Send a welcome email. See [Callouts](/components/callouts) for how to flag side effects. |
```

To put a literal `|` inside a cell, escape it as `\|`.

## In the visual editor

Type `/` and pick **Table** to insert a three-by-three table with a header row. Click a cell to type, and press `Tab` or `Shift+Tab` to move between cells.

While the cursor is in a table, a toolbar lets you add a column before or after, add a row above or below, delete the current row or column, or delete the whole table.

<Callout type="tip">
  Tables work best with two to five columns. For API parameters with nested fields, try [API fields](https://docs.typemark.dev/components/api-fields) instead.
</Callout>
