Flutter Merge Threads #BreakingChanges
In older versions, Flutter ran multiple threads to keep things smooth:
- UI Thread → where your Dart code runs.
- Raster Thread → where the engine turns that UI into pixels.
These two worked in sync to render frames efficiently.
Alongside them, Flutter also had the Platform Thread, which runs native code (Swift on iOS or Kotlin/Java on Android).
Every time Flutter needed to talk to these threads — Dart ↔ native, it caused problems.
Therefore, Platform Channels were built for the transmission of messages between the threads and languages.
You’d often use the Pigeon package to define the interface between Dart and native, but since platform calls are synchronous while Dart Futures are asynchronous, it got… complicated. Every payload had to be serialized, and every call had to bounce between threads and languages.
What’s Changing Now
With Flutter 3.35, the engine is getting smarter.
All Dart code is being migrated onto the main Platform Thread, bridging the gap between Dart and native more directly.
This allows FFI (Foreign Function Interface) to preserve type safety while calling native Swift or Kotlin code, no more fragile serialization back-and-forth.
The migration is rolling out in two phases, and it’s not yet fully applied everywhere, but it’s happening fast.
What You Should Do
If you have custom logic running on the Platform Thread, it’s time to relocate it.
Because with the Flutter UI thread now merging into the platform thread, heavy computations could block your UI and break frame budgets.
Move expensive work to standalone isolates instead.
Example
Before the merge, we had to write asynchronous code even when the underlying native function was synchronous.
Flutter’s calls to those APIs had to go through a Platform Channel and therefore, had to be async.
// Old
Future<double> getBatteryCharge();Now, it is much simpler:
// New
double getBatteryCharge();That’s right! No more async placeholder!
Since the call is now synchronous, there’s no need for:
- Null checks
initStatesetup- Helper async wrappers
- Even
StatefulWidgetin some cases!
TL;DR
Flutter’s Merge Threads is all about simplifying the bridge between Dart and native layers, cutting down async overhead, improving type safety, and letting the engine run closer to the metal.
Less thread hopping.
Less serialization.
More performance.
About Me
I am Zaahra, a Google Women Techmakers Ambassador who enjoy mentoring people and writing about technical contents that might help people in their developer journey. I also enjoy building stuffs to solve real life problems.
To reach me:
LinkedIn: https://www.linkedin.com/in/faatimah-iz-zaahra-m-0670881a1/
X (previously Twitter): _fz3hra
GitHub: https://github.com/fz3hra
Cheers,
Umme Faatimah-Iz-Zaahra Mujore | Google Women TechMakers Ambassador | Software Engineer