The Flutter Kit logoThe Flutter Kit
Boilerplate · Supabase

Flutter Supabase Boilerplate: Swap the Kit onto Supabase

The Flutter Kit ships on Firebase by default, but you own every line of Dart — so swapping it onto Supabase for auth, Postgres, realtime, and storage is a deliberate, file-by-file job, not a fork-and-pray rewrite. Here's exactly where the seams are.

Last updated: 2026-06-08 7 min read By Ahmed Gagan, Flutter Engineer
Quick Answer

The Flutter Kit is a flutter supabase boilerplate-ready starter at $69 one-time (was $149) — it ships on Firebase, but because you get full Dart source ownership, the repository pattern lets you swap the data layer onto Supabase without touching your UI. Supabase auth replaces Firebase Auth, Postgres + Row Level Security replaces Firestore, Supabase Realtime replaces Firestore streams, and Supabase Storage replaces Cloud Storage. The BLoC + get_it architecture means you re-implement repository classes, not screens.

Swap surface
Repository classes only — UI untouched
Auth mapping
Firebase Auth → supabase_flutter GoTrue
Data mapping
Firestore → Postgres + RLS + Realtime
Price
$69 one-time, full source, lifetime updates

Why the architecture makes the swap survivable

Most boilerplates wire Firebase calls directly into widgets, so moving to Supabase means hunting through every screen. The Flutter Kit uses the repository pattern with dependency injection through get_it: your BLoCs and Cubits depend on an abstract repository interface, and the concrete Firebase implementation is registered in one DI file. To go Supabase, you write a new concrete implementation of the same interface and change one registration line. The flutter_bloc layer, your screens, and your Material 3 theming never know the backend changed. This is the single reason a Supabase swap is realistic here rather than a multi-week rewrite — you're replacing the bottom of the stack, not rebuilding it.

  • Abstract repository interfaces sit between BLoC and the backend SDK
  • get_it registers the concrete backend in one place
  • UI, routing (go_router), and theming stay byte-for-byte identical

Auth: Firebase Auth → Supabase GoTrue

Swap the firebase_auth dependency for supabase_flutter and re-implement your AuthRepository against Supabase's GoTrue client. Email/password maps cleanly; Google and Apple sign-in move to Supabase OAuth providers configured in the Supabase dashboard, and anonymous sessions are supported via signInAnonymously. The auth state stream that drives your BLoC becomes Supabase's onAuthStateChange. RevenueCat identity still keys off your app user ID, so payments keep working untouched — you just feed it the Supabase user UID instead of the Firebase UID.

Data, realtime, and storage

This is where Supabase changes how you think. Firestore documents become Postgres rows, and access rules move from Firestore security rules to Row Level Security policies written in SQL — stricter and more auditable, but a real mindset shift. Your Firestore streams (snapshots) become Supabase Realtime channel subscriptions, which your Cubits consume the same way. Cloud Storage uploads become Supabase Storage buckets with signed URLs. The OpenAI features still run through the kit's Flask proxy, so your API keys stay off-device regardless of backend.

  • Firestore queries → typed Postgres queries via PostgREST
  • Firestore listeners → Supabase Realtime subscriptions in your Cubit
  • Cloud Storage → Supabase Storage buckets + RLS-guarded signed URLs

When you should just stay on Firebase

Be honest with yourself before committing to the swap. If you want FCM push, Cloud Functions, GA4 wired in, and a working AI proxy on day one, the kit's default Firebase path is already done and tested — the Supabase swap is real engineering work you're choosing to take on. Supabase wins when you need relational data with joins, SQL you can query directly, predictable self-hostable pricing, or you simply prefer Postgres. Firebase wins for fastest time-to-launch, the most mature Flutter push tooling, and serverless functions out of the box. Pick Supabase for the data model, not because it's trendy.

Supabase swap: The Flutter Kit vs starting from scratch

The Flutter Kit (swapped to Supabase) vs Build Supabase app from scratch comparison
FeatureThe Flutter Kit (swapped to Supabase)Build Supabase app from scratch
Price$69 one-timeFree code, weeks of your time
Source ownershipFull Dart source, MIT-style ownershipYours, but you write it all
ArchitectureBLoC + get_it + repository pattern readyYou design it yourself
Swap effortRe-implement repositories onlyEverything is from-scratch effort
Auth, payments, AI, onboardingPre-built (RevenueCat, OpenAI proxy, 3 onboarding templates)Not included
Material 3 themingCentralized design tokens, retheme in one fileHand-rolled

Frequently Asked Questions

Does The Flutter Kit ship with Supabase already wired in?
No. It ships on Firebase by default. Because you own the full Dart source and it uses the repository pattern, you swap the data layer onto Supabase by re-implementing repository classes against supabase_flutter — your UI, BLoC, and theming stay unchanged.
How much of the kit breaks when I move to Supabase?
Only the concrete backend implementations registered in get_it. Your screens, go_router routes, Material 3 tokens, onboarding templates, and RevenueCat paywalls are backend-agnostic and keep working as-is.
What replaces Firestore security rules on Supabase?
Postgres Row Level Security (RLS) policies written in SQL. It's a mindset shift from Firestore's rule syntax, but RLS is stricter, auditable, and lives next to your data — a benefit for relational apps.
Do RevenueCat payments still work after the Supabase swap?
Yes. RevenueCat keys off your app user ID and runs through StoreKit 2 and Play Billing independent of your backend. You just pass the Supabase user UID as the app user ID instead of the Firebase UID.
Will I lose push notifications by leaving Firebase?
FCM is the most mature Flutter push path, so if you rely on the kit's push diagnostics and FCM setup, that's the one area where leaving Firebase costs you. Many teams keep FCM for push while using Supabase for data — a valid hybrid.
Is the Supabase swap worth it over just using Firebase?
Only if you need relational data, SQL queries with joins, or predictable self-hostable pricing. If you want the fastest launch with push, functions, and the AI proxy working immediately, the default Firebase path is already done and tested.

Keep exploring

Own the source. Swap the backend on your terms.

Get The Flutter Kit for $69 one-time and you own every line of Dart — start on Firebase today, swap to Supabase auth, Postgres, realtime, and storage whenever your data model demands it. No subscription, lifetime updates, unlimited projects.

Get The Flutter Kit — $69

One-time purchase · Lifetime updates · Unlimited projects