> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nemu.cc/llms.txt
> Use this file to discover all available pages before exploring further.

# Fonts and weights

> Six bundled variable fonts, real weight instancing, and loading custom variable fonts

Six variable fonts are bundled and registered automatically. Use them by name in
`font_family`.

| Name             | Style     |
| ---------------- | --------- |
| `inter`          | sans      |
| `geist`          | sans      |
| `geist-mono`     | monospace |
| `nunito-sans`    | sans      |
| `roboto`         | sans      |
| `source-serif-4` | serif     |

```ts theme={null}
{ type: "paragraph", text: "Body text", style: { font_family: "source-serif-4" } }
```

## Weights

`font_weight` selects a real weight by instancing the variable font at build time. Names map
to the usual axis values, and numbers pass straight through.

| Name         | Number |
| ------------ | ------ |
| `thin`       | 100    |
| `extralight` | 200    |
| `light`      | 300    |
| `regular`    | 400    |
| `medium`     | 500    |
| `semibold`   | 600    |
| `bold`       | 700    |
| `extrabold`  | 800    |
| `black`      | 900    |

```ts theme={null}
{ type: "paragraph", text: "Heavy", style: { font_family: "inter", font_weight: "black" } }
{ type: "paragraph", text: "Light", style: { font_family: "inter", font_weight: 300 } }
```

Markdown `**bold**` and the `strong` inline node also produce a real bold weight. See
[Inline content](/packages/pdf/doc/inline).

<Note>
  The bundled fonts are upright only, with no italic axis, so `em` and `*italic*` render the
  same glyphs as regular text. Use `strong`, `**bold**`, or a heavier `font_weight` for
  emphasis that is visible.
</Note>

## Custom variable fonts

Load a custom variable font with `load_font` and pass `variable: true` to enable weight
instancing. Then use the registered name in `font_family`.

```ts theme={null}
doc.load_font("my-sans", "./fonts/MySans.ttf", true);

doc.page().content(
  { type: "paragraph", text: "Custom font", style: { font_family: "my-sans", font_weight: "semibold" } },
);
```
