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

# #font — Custom Fonts

> Import custom font files into your app

The `#font` command imports custom font files into your Xcode project and sets them up so you can use them anywhere in your app. No manual Info.plist editing or font registration required.

## What It Does

When you use `#font`, the AI handles the full setup process:

1. Adds the font file to your Xcode project
2. Registers it in your app's **Info.plist** under `UIAppFonts`
3. Creates a SwiftUI `Font` extension so the font is easy to reference throughout your code

After that, your custom font is available everywhere in your app — headings, body text, buttons, labels, wherever you need it.

## Supported Formats

| Format  | Full name     | Notes                                  |
| ------- | ------------- | -------------------------------------- |
| **TTF** | TrueType Font | The most widely supported font format  |
| **OTF** | OpenType Font | Supports advanced typographic features |

## How to Use

<Steps>
  <Step title="Type #font in the chat">
    Type `#` and select **font** from the toolkit popover.
  </Step>

  <Step title="Select your font file">
    The file picker opens, filtered to TTF and OTF files. Choose the font you want to import.
  </Step>

  <Step title="Describe how to use it">
    The font appears as an orange chip below the input. Tell the AI where to apply the font in your app.
  </Step>

  <Step title="Send your message">
    Press Enter. The AI registers the font, creates the necessary extensions, and applies it as described.
  </Step>
</Steps>

## Example Prompts

```
Use this font for all heading text
```

```
Apply this as the body font throughout the app
```

```
Use this font for the logo text at size 32
```

```
This is the bold weight — use it for buttons and navigation titles
```

```
Apply this font to the onboarding screen titles at size 28
```

## What Happens Behind the Scenes

When you attach a font, the AI does three things automatically:

1. **Adds the file** — The `.ttf` or `.otf` file is added to your Xcode project and included in the app bundle.
2. **Registers in Info.plist** — The font filename is added to the `UIAppFonts` array so iOS knows to load it at launch.
3. **Creates a Font extension** — A SwiftUI extension is generated so you can use the font with a clean API like `.font(.customHeading)` instead of referencing the PostScript name directly.

<Tip>
  Import all font weights at once if you have them (Regular, Bold, Italic, etc.). Describe which weight to use where, and the AI will set up each one with its own extension.
</Tip>

<Warning>
  Some fonts have licensing restrictions. Make sure you have the right to use the font in your app before importing. Many free fonts are available from Google Fonts and other open-source libraries.
</Warning>

## Common Font Sources

| Source                                    | License      | Notes                                       |
| ----------------------------------------- | ------------ | ------------------------------------------- |
| [Google Fonts](https://fonts.google.com)  | Open source  | Hundreds of free fonts                      |
| [Font Squirrel](https://fontsquirrel.com) | Varies       | Free fonts, most are app-licensed           |
| Adobe Fonts                               | Subscription | Requires Creative Cloud license             |
| Custom / purchased                        | Varies       | Check your license for app embedding rights |

## Related

<CardGroup cols={2}>
  <Card title="Toolkit Overview" icon="grid-2" href="/toolkit/overview">
    See all available # commands and how the toolkit works.
  </Card>

  <Card title="Chat Interface" icon="message" href="/features/chat-interface">
    Learn more about the chat input and how to interact with the AI.
  </Card>
</CardGroup>
