Skip to main content
RapidDev - Software Development Agency
flutterflow-tutorials

How to Create a Custom Theme for Your FlutterFlow App

FlutterFlow's Theme Settings let you define your app's color palette, typography styles, border radius, and spacing system in one place. Set primary, secondary, tertiary, background, surface, and error colors with light and dark mode variants. Define heading and body text styles with custom font families, sizes, and weights. All widgets reference these Theme values so changing one color updates your entire app instantly.

What you'll learn

  • How to configure a complete color palette in Theme Settings with light and dark variants
  • How to set up typography styles for headings and body text with custom fonts
  • How to enable and configure dark mode with a separate color set
  • How to access Theme values in Custom Code using FlutterFlowTheme.of(context)
Book a free consultation
4.9Clutch rating
600+Happy partners
17+Countries served
190+Team members
Beginner6 min read15-20 minFlutterFlow Free+March 2026RapidDev Engineering Team
TL;DR

FlutterFlow's Theme Settings let you define your app's color palette, typography styles, border radius, and spacing system in one place. Set primary, secondary, tertiary, background, surface, and error colors with light and dark mode variants. Define heading and body text styles with custom font families, sizes, and weights. All widgets reference these Theme values so changing one color updates your entire app instantly.

Setting Up a Design System with FlutterFlow Themes

A consistent theme is the foundation of a professional app. FlutterFlow's Theme Settings act as your design system — you define colors, fonts, and spacing once, and every widget in your app can reference them. This means changing your brand color in one place updates buttons, text, icons, and backgrounds everywhere. Set up your theme before building pages.

Prerequisites

  • A FlutterFlow project open in the builder
  • Your brand colors as hex codes (primary, secondary, accent, background)
  • Your desired font family (Google Fonts or custom TTF/OTF files)

Step-by-step guide

1

Open Theme Settings and configure your color palette

Click the paintbrush icon in the left Navigation Menu to open Theme Settings. Under Colors, you will see slots for Primary, Secondary, Tertiary, Alternate, Background, Surface, and Error. Click each color swatch and enter your hex code. For Primary, use your main brand color. For Background, use your page background. For Surface, use the color for cards and elevated elements. For Error, keep a red tone for validation messages. Each color also has a light variant — set this to a lighter shade of the same hue for hover states and subtle backgrounds.

Expected result: All color slots in Theme Settings show your brand colors.

2

Define your typography hierarchy with font families and sizes

Still in Theme Settings, switch to the Typography tab. FlutterFlow provides named styles from Display Large down to Body Small. For each style, set the Font Family (click to search Google Fonts or select your uploaded custom font), font size (in pixels), font weight (Regular 400, Medium 500, SemiBold 600, Bold 700), and letter spacing. A common starting point: Headline Large at 32px Bold, Headline Small at 20px SemiBold, Body Medium at 16px Regular, Body Small at 14px Regular.

Expected result: Each typography style shows your selected font family, size, and weight in the Theme Settings preview.

3

Apply Theme colors and typography to widgets on your pages

Navigate to any page and select a widget — for example, a Button. In the Properties Panel, click the color field for the button background. Switch to the Theme Color tab in the color picker and select Primary. For a Text widget, click the text style dropdown and select a Theme typography style like Headline Small or Body Medium. Now these widgets automatically update when you change the Theme values.

Expected result: Widgets display colors and typography from your Theme, and update instantly when Theme values change.

4

Enable and configure dark mode with a separate color palette

In Theme Settings, click the Dark Mode toggle to enable it. FlutterFlow creates a duplicate color palette for dark mode. Update each dark mode color: swap your light Background (#FFFFFF) for a dark one (#121212), swap Surface to a dark elevated color (#1E1E1E), and adjust Primary to a lighter shade if needed for contrast on dark backgrounds. Typography remains the same — only colors change between light and dark modes.

Expected result: Switching the theme preview between Light and Dark shows your two distinct color palettes applied.

5

Access Theme values in Custom Code using FlutterFlowTheme

When writing Custom Widgets or Custom Actions, access your theme programmatically. Use FlutterFlowTheme.of(context).primary for the primary color, FlutterFlowTheme.of(context).bodyMedium for body text style, and FlutterFlowTheme.of(context).bodyMediumFamily for the font family name. This keeps your Custom Code consistent with the visual builder's theme settings.

theme_access_example.dart
1// Access theme colors
2final primaryColor = FlutterFlowTheme.of(context).primary;
3final backgroundColor = FlutterFlowTheme.of(context).primaryBackground;
4
5// Access typography
6final headingStyle = FlutterFlowTheme.of(context).headlineSmall;
7final bodyStyle = FlutterFlowTheme.of(context).bodyMedium;
8
9// Example usage in a widget
10Text(
11 'Hello World',
12 style: FlutterFlowTheme.of(context).headlineSmall.override(
13 fontFamily: FlutterFlowTheme.of(context).headlineSmallFamily,
14 color: FlutterFlowTheme.of(context).primary,
15 ),
16);

Expected result: Custom Code widgets render with the same colors and fonts defined in Theme Settings.

Complete working example

FlutterFlow Theme Configuration
1THEME SETTINGS COLORS (Light Mode):
2 Primary: #4B39EF (brand purple)
3 Secondary: #39D2C0 (teal accent)
4 Tertiary: #EE8B60 (warm orange)
5 Alternate: #E0E3E7 (light grey)
6 Primary Background: #F1F4F8 (off-white)
7 Secondary Background: #FFFFFF (white)
8 Surface (cards): #FFFFFF
9 Error: #FF5963 (red)
10
11THEME SETTINGS COLORS (Dark Mode):
12 Primary: #6C5CE7 (lighter purple)
13 Secondary: #39D2C0 (same teal)
14 Tertiary: #EE8B60 (same orange)
15 Alternate: #262D34 (dark grey)
16 Primary Background: #1D2428 (near-black)
17 Secondary Background: #14181B (black)
18 Surface (cards): #262D34
19 Error: #FF5963 (same red)
20
21THEME SETTINGS TYPOGRAPHY:
22 Display Large: Plus Jakarta Sans, 57px, Bold 700
23 Headline Large: Plus Jakarta Sans, 32px, Bold 700
24 Headline Small: Plus Jakarta Sans, 20px, SemiBold 600
25 Title Medium: Plus Jakarta Sans, 18px, SemiBold 600
26 Body Large: Plus Jakarta Sans, 16px, Regular 400
27 Body Medium: Plus Jakarta Sans, 14px, Regular 400
28 Body Small: Plus Jakarta Sans, 12px, Regular 400
29 Label Medium: Plus Jakarta Sans, 12px, Medium 500
30
31CUSTOM CODE ACCESS:
32 Color: FlutterFlowTheme.of(context).primary
33 Style: FlutterFlowTheme.of(context).headlineSmall
34 Font: FlutterFlowTheme.of(context).bodyMediumFamily

Common mistakes when creating a Custom Theme for Your FlutterFlow App

Why it's a problem: Hardcoding hex colors directly on individual widgets

How to avoid: Always select colors from the Theme Color tab in the color picker. This creates a reference to the Theme value that updates globally.

Why it's a problem: Setting up pages before configuring the Theme

How to avoid: Always configure Theme Settings (colors, typography, spacing) before building any pages.

Why it's a problem: Using more than two font families in the app

How to avoid: Limit your app to two font families maximum — one for headings and one for body text. Use weight variations (Regular, Medium, Bold) for visual hierarchy instead of additional fonts.

Best practices

  • Configure your complete Theme (colors, typography, spacing) before building any pages
  • Use no more than two font families — differentiate hierarchy with weight and size
  • Always use Theme Color references on widgets instead of hardcoded hex values
  • Set up dark mode colors immediately, even if you launch with light mode only
  • Test your color palette for accessibility — ensure sufficient contrast between text and background
  • Access Theme values in Custom Code via FlutterFlowTheme.of(context) for consistency
  • Document your color naming convention so team members use the right semantic color

Still stuck?

Copy one of these prompts to get a personalized, step-by-step explanation.

ChatGPT Prompt

I need to set up a complete theme for my FlutterFlow app with a modern color palette (primary, secondary, background, surface, error) in both light and dark mode. Suggest a professional color scheme and typography hierarchy using Google Fonts.

FlutterFlow Prompt

Update my app's theme. Set the primary color to #4B39EF, secondary to #39D2C0, background to #F1F4F8. Use Plus Jakarta Sans for all text styles.

Frequently asked questions

Can I import a theme from Figma into FlutterFlow?

FlutterFlow does not have a direct Figma theme import. You need to manually copy hex color values and font specifications from your Figma design system into Theme Settings.

How do I switch between light and dark mode at runtime?

FlutterFlow provides a built-in Toggle Dark Mode action. Add it to a Switch widget or button On Tap action. The app instantly switches between your light and dark color palettes.

Can I have more than one theme in my app?

FlutterFlow supports one light theme and one dark theme. You cannot switch between multiple brand themes at runtime. For multi-brand apps, you would need Custom Code.

Do Theme changes affect already-built pages?

Yes — any widget that references Theme Colors or Theme Typography updates automatically when you change Theme Settings. Only widgets with hardcoded values remain unchanged.

What is the difference between Primary and Secondary colors?

Primary is your main brand color used for buttons, app bars, and key actions. Secondary is an accent color for less prominent elements, toggles, and secondary buttons. This follows Material Design conventions.

Can RapidDev help design a professional theme for my app?

Yes. RapidDev's team can create a complete design system with color palette, typography, spacing, and dark mode that matches your brand guidelines and accessibility requirements.

RapidDev

Talk to an Expert

Our team has built 600+ apps. Get personalized help with your project.

Book a free consultation

Need help with your project?

Our experts have built 600+ apps and can accelerate your development. Book a free consultation — no strings attached.

Book a free consultation

We put the rapid in RapidDev

Need a dedicated strategic tech and growth partner? Discover what RapidDev can do for your business! Book a call with our team to schedule a free, no-obligation consultation. We'll discuss your project and provide a custom quote at no cost.