#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:
- Adds the font file to your Xcode project
- Registers it in your app’s Info.plist under
UIAppFonts - Creates a SwiftUI
Fontextension so the font is easy to reference throughout your code
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
Select your font file
The file picker opens, filtered to TTF and OTF files. Choose the font you want to import.
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.
Example Prompts
What Happens Behind the Scenes
When you attach a font, the AI does three things automatically:- Adds the file — The
.ttfor.otffile is added to your Xcode project and included in the app bundle. - Registers in Info.plist — The font filename is added to the
UIAppFontsarray so iOS knows to load it at launch. - 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.
Common Font Sources
| Source | License | Notes |
|---|---|---|
| Google Fonts | Open source | Hundreds of free fonts |
| Font Squirrel | 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
Toolkit Overview
See all available # commands and how the toolkit works.
Chat Interface
Learn more about the chat input and how to interact with the AI.