Kasikornbank Amorn Apichattanakul Jul 20, 2026

Flutter Too Slow for Images? Rush It With Rust

Article Summary

Amorn Apichattanakul from KBTG just shattered a common Flutter myth: it's not the language that's slow, it's the codec. His benchmark results are eye-opening.

A Google Developer Expert for Flutter tested image processing performance across six different approaches: pure Dart, Kotlin via MethodChannel, and Rust via FFI. The results challenge everything developers assume about Flutter performance bottlenecks and bridge overhead.

Key Takeaways

Critical Insight

The performance gap between Dart and native isn't about the language or FFI overhead, it's about which codec library you're using and whether it leverages SIMD instructions.

The article includes a step-by-step guide with specific traps to avoid when integrating Rust into your Flutter app, plus the exact libraries that delivered native-level performance.

About This Article

Problem

Amorn Apichattanakul found that isolates, which are commonly used to prevent UI freezing in Flutter image processing, actually made things slower. The isolate version ran 2x slower at 5009ms compared to 2957ms, and it used 127MB extra memory because of data copying to background efficiency cores.

Solution

He integrated Rust into Flutter using flutter_rust_bridge, which auto-generates FFI glue code and compiles Rust during the normal Flutter build process. This eliminated the need to manually manage .so files or write platform-specific code in Kotlin and Swift.

Impact

By switching to optimized Rust libraries like zune-jpeg, fast_image_resize, and jpeg-encoder, processing time dropped from 205ms to 142ms. That's only 10ms slower than native Kotlin, and it added just 0.8MB to the APK size.