This guide explains how to use the custom fonts (Albra family and Gilroy) in your React Native app.
All fonts have been successfully linked to both iOS and Android platforms. You can now use them throughout your app.
Optimized for readability at smaller sizes. Perfect for body text and long-form content.
Weights: Light, Regular, Medium, Semi Bold, Bold, Black Includes: Italic variants for all weights
Usage:
import { AppFonts } from './src/constants/fonts';
<Text style={{ fontFamily: AppFonts.body.regular }}>
Your paragraph text here
</Text>Optimized for large sizes. Perfect for hero sections, page titles, and large headings.
Weights: Light, Regular, Medium, Semi Bold, Bold, Black Includes: Italic variants for all weights
Usage:
<Text style={{ fontFamily: AppFonts.display.bold, fontSize: 32 }}>
Page Title
</Text>Clean sans-serif perfect for interface elements like buttons, tabs, and labels.
Weights: Light, Regular, Medium, Semi Bold, Bold, Black Includes: Italic variants for all weights
Usage:
<Text style={{ fontFamily: AppFonts.ui.semiBold }}>
Button Text
</Text>Modern geometric sans-serif. Great for tech-focused or minimalist designs.
Weights: Light, Regular, Medium, Bold, Heavy
Usage:
<Text style={{ fontFamily: AppFonts.geometric.bold }}>
Modern Heading
</Text>Another geometric option from the Albra family. Clean and modern.
Weights: Light, Regular, Medium, Semi Bold, Bold, Black Includes: Italic variants for all weights
Usage:
<Text style={{ fontFamily: AppFonts.grotesk.medium }}>
Clean Interface Text
</Text>The original Albra family. Versatile for various uses.
Weights: Thin, Light, Regular, Medium, Semi Bold, Bold, Black Includes: Italic variants (except Thin)
The easiest way to use fonts is with the preset TextStyles:
import { TextStyles } from './src/constants/fonts';
// Hero text
<Text style={TextStyles.hero}>Welcome!</Text>
// Page title
<Text style={TextStyles.title}>Dashboard</Text>
// Section heading
<Text style={TextStyles.heading}>Recent Activity</Text>
// Body text
<Text style={TextStyles.body}>
This is a paragraph of text that will be easy to read...
</Text>
// Button text
<Text style={TextStyles.button}>Submit</Text>
// Caption
<Text style={TextStyles.caption}>Last updated 2 hours ago</Text>For more control, use fonts directly:
import { AppFonts, FontSizes } from './src/constants/fonts';
<Text style={{
fontFamily: AppFonts.display.bold,
fontSize: FontSizes.heading.h1,
lineHeight: FontSizes.heading.h1 * 1.3,
}}>
Custom Heading
</Text>- Long paragraphs: AlbraText (optimized for reading)
- Large headings: AlbraDisplay (looks great at big sizes)
- Buttons/UI: AlbraSans (clean, interface-friendly)
- Modern aesthetic: Gilroy or AlbraGrotesk
Use different weights and sizes to create visual hierarchy:
// Primary heading
<Text style={{ fontFamily: AppFonts.display.bold, fontSize: 32 }}>
// Secondary heading
<Text style={{ fontFamily: AppFonts.display.semiBold, fontSize: 24 }}>
// Body text
<Text style={{ fontFamily: AppFonts.body.regular, fontSize: 16 }}>For better readability:
- Headings: 1.2 - 1.3 × font size
- Body text: 1.5 - 1.6 × font size
{
fontFamily: AppFonts.body.regular,
fontSize: 16,
lineHeight: 24, // 1.5 × 16
}- Light: Subtle, minimal
- Regular: Default text
- Medium: Slight emphasis
- Semi Bold: More emphasis
- Bold: Strong emphasis
- Black: Maximum impact
Use consistent font sizes throughout your app:
- Large: 48px
- Medium: 40px
- Small: 36px
- H1: 32px (Page titles)
- H2: 28px (Section headings)
- H3: 24px (Subsection headings)
- H4: 20px (Card titles)
- H5: 18px (Small headings)
- H6: 16px (Tiny headings)
- Large: 18px (Emphasized paragraphs)
- Regular: 16px (Standard body text)
- Small: 14px (Secondary text)
- Large: 16px
- Regular: 14px
- Small: 12px
- Tiny: 10px
When using fonts directly with fontFamily, use these exact names:
Both platforms use the same font names:
// AlbraText
'AlbraText-Regular'
'AlbraText-Bold'
// etc.
// AlbraDisplay
'AlbraDisplay-Regular'
'AlbraDisplay-Bold'
// etc.
// Gilroy
'Gilroy-Regular'
'Gilroy-Bold'
// etc.Note: OTF and TTF fonts work identically in React Native CLI. No platform-specific handling needed!
See src/components/FontShowcase.tsx for a complete example showcasing all available fonts and styles.
To view it, import and use the component:
import FontShowcase from './src/components/FontShowcase';
// In your navigator or screen
<FontShowcase />-
Clean and rebuild:
# iOS yarn run reset:ios yarn ios # Android yarn run clean:android yarn android
-
Check font names: Ensure you're using exact font names from
src/constants/fonts.ts -
Check Info.plist (iOS): All fonts should be listed under
UIAppFontskey -
Check Android assets: Fonts should be in
android/app/src/main/assets/fonts/
-
iOS: Clean build folder, re-run pod install
cd ios && pod install && cd .. yarn ios
-
Android: Clean gradle build
cd android && ./gradlew clean && cd .. yarn android
- Update your existing components to use the new fonts
- Create a theme configuration that includes these font styles
- Consider creating reusable Text components for consistent typography
- Test fonts on both iOS and Android devices
Happy coding with beautiful typography!