Flutter is one of the most popular cross-platform mobile development tools. Learn about the pros and cons of Flutter development.
Active iPhone and Android devices run into billions of units. The market opportunity is enormous, letting businesses tap into a broad and diverse user base. Cross-platform development solutions help businesses ship their digital products to Android and iOS at the same time, all at a lower price and with faster delivery.
Flutter is one of the most popular cross-platform development tools for building applications that run on iOS, Android, web, and desktop. Learn what are the pros and cons of Flutter.
What Is Flutter?
Flutter is a UI software development kit developed by Google in 2015 (released as a beta version in 2017).
With Flutter, you can build native mobile applications that run from a single codebase on multiple platforms (e.g., Android, iOS).
When you write apps in Flutter, they are natively compiled. That is, they aren’t written in the native programming language valid for iOS or Android, but they are compiled into native code. In the case of Flutter, the compilation happens ahead of time.
Ahead-of-time (AOT) compilation ”converts” the app’s code to native code at build time. AOT compilation enables a mobile device to run the code natively.
Just-in-time (JIT) compilation “converts” only parts of the code depending on what’s required at runtime.
Which programming language is used in Flutter?
Flutter uses Dart — a general-purpose programming language created by Google back in 2011. The official programming language for native iOS and Android development is Swift and Kotlin, respectively.
What platforms does Flutter support?
The upside of Flutter programming is that you can use Flutter to build a product for iOS, Android, web, and desktop — all from a single codebase.
Since 2016, Google’s been developing Fuchsia, the company’s new operating system, which is an experimental platform to explore the possibilities of a cross-device operating system.
There’s no release date yet and no specific information as to how exactly Fuchsia would be used by consumers. However, Dart and Flutter will be used in Fuchsia development. Leveraging Dart and Flutter today might as well make the transition to a new ecosystem smoother if that ecosystem will be marketed in the future.
Pros of Flutter App Development
Easy cross-platform app updates
When you have the same codebase for iOS, Android, and the web, app updates are more streamlined.
Backend updates are also done once per update. This decreases the risk of possible synchronization issues when there are separate teams of developers responsible for each platform (like in native development).
Good app performance
Flutter might not yet be on par performance-wise with natively built apps, at least not in every scenario. But apps developed in Flutter are still responsive and fast.
Companies such as Tencent or Square have plenty of users to please with the experiences their customers get inside the apps. If performance was an issue, renowned brands wouldn’t include Flutter in their tech stacks.
Still, there are threads on Reddit or Stack Overflow where developers are asking why their Flutter apps are slow.
The reason why some Flutter apps are slow usually doesn’t have anything to do with Flutter itself.
In fact, poor performance most often comes from the lack of skills and sufficient knowledge of Dart and cross-platform development. If you follow best practices in Flutter development, you’ll build fast apps. The documentation for Flutter has a full section with recommended best practices that help keep Flutter apps performant.
Less code
When you have one codebase that powers apps that run on multiple platforms, the amount of code you have to write and then maintain drops considerably.
It’s not to say that you won’t have to make platform-specific tweaks in the code, but the amount of code will be nowhere close to separate codebases for iOS and Android as seen in native development.
Less testing
When there’s less code to work with, there’s less testing required to push out each iteration of a Flutter app.
In native development, when you have a separate codebase for iOS and Android, each new release of the app has to be tested for both platforms.
In Flutter, you can write one test and run it across all platforms your Flutter works on (e.g., iOS, Android, and desktop).
Fast time-to-market
The idea behind Flutter is to maximize code reuse across platforms. And while you can’t expect to reduce development time by half, Flutter lets you shave off a significant chunk of that time.
With Flutter, the majority of the codebase will be the same for all the platforms.
When you want to validate your idea quickly, get investors, or simply capture a user base, cross-platform solutions such as Flutter will be a great choice for app development.
Convenient ready-made UI elements
Flutter gives developers a whole collection of UI elements that further speed up production. While ready-made UI components might affect branding opportunities, Flutter also lets devs customize each component, with platform-specific tweaks.
Flutter’s engine makes the UI elements render with high FPS which results in a positive user experience.
Hot reload
The hot reload feature lets developers look up changes to the code instantly, without wasting time to recompile the code. Hot reload helps developers quickly fix bugs and introduce and evaluate changes to UI components.
Cons of Flutter App Development
Libraries growing but not yet mature
Flutter’s repository is constantly growing; however, the tooling isn’t yet as mature as, for example, React Native’s.
Because there are comparably fewer plugins in Flutter, some of the functionalities have to be supplied by open-source plugins made by the Flutter community. Another drawback is that Flutter tends to be favored by developers with a native Android background, which affects the quality and functionality of iOS libraries for Flutter.
So when your app needs a highly specific functionality, it can turn out that there’s no third-party library available to support it. Also, libraries that do support it might be low quality or no longer maintained. In that case, you’ll have to write the plugin yourself.
For example, in one of our projects, Flutter’s subscription library didn’t have the option to download the end-of-subscription date necessary to validate a user’s privileges — we had to write the feature natively for iOS.
Need for native development skills
While that’s not necessarily a drawback, when you need a native functionality, you’ll need to develop native bridges to implement that functionality into a specific platform. The bridge has to be written in a native programming language of that platform (e.g., Kotlin/Java for Android and Swift/Objective-C for iOS).
Issues with animations
When you follow Flutter’s best practices during development, you can expect good performance results. However, there’s one performance issue that’s been getting a lot of coverage recently.
Developers have found that in some instances animations are jittery at first render in Flutter apps (iOS and Android both).
This information is valid as of April 2021. We’ll be updating the content the moment we learn that Flutter has resolved the problem.
Why and When You Shouldn’t Use Flutter?
If your app will be using complex APIs that require bridges to iOS or Android for specific functionalities, you’ll have to deal with lots of native code. In other words, complex applications that rely on platform-specific features might not be a good fit for Flutter.
Is Flutter Safe for Production?
Because Flutter is relatively young (2017), many companies have initially excluded it from their tech stacks. Back then, there were few skilled Flutter devs available (Flutter uses Dart, a much less popular programming language compared to, for example, JavaScript — the most popular programming language in the world — used in React Native).
Also, young technologies usually need to gain more traction and maturity for larger companies to consider them.
Should I Use Flutter or Go Native?
It all depends on your project.
Let’s ponder the question from the perspective of a specific use case.
If you want to develop a product that spans a whole ecosystem, e.g., iPhone, CarPlay, Apple Watch, or iPad, you’d be better off with native development for the majority of reasons stated above (the need to write a lot of native code and then maintain it).
Also, if your app will be using functionalities not covered by Flutter plugins, you’ll need developers skilled in native development to write bridges to implement these functionalities.
That’s why we recommend Flutter for:
- minimum viable products (MVP)
- proof of concepts (POC)
- or whenever you have limited resources and need to maximize the learning about your product in the little time you have
If you want to validate your idea or develop an MVP quickly and launch it for two platforms at once, Flutter is a better choice than native development.
Developing mobile apps in Flutter significantly speeds up the development process, so you can start probing the market with your product faster than you would when developing two separate codebases (for iOS and Android).
Migration to Flutter
You can also migrate to Flutter from your existing native iOS and Android app if that app isn’t overly complex and doesn’t use many platform-specific features. In that case, you can gradually implement Flutter into the tech stack.
Note: With existing native apps, the transition to a new technology is never a one-day event. It’s an incremental process where you gradually incorporate components written in Flutter. In time, you’ll have a cross-platform Flutter app with appropriate native bridges.
Once you’ve migrated to Flutter, you’ll experience the benefits of having less code to maintain, being able to launch updates faster, addressing bugs more effectively, and having a single codebase that can run on iOS, Android, desktop, and web.
App Examples in Flutter
Philips Hue is a smart system for controlling in-house lighting. Philips went with Flutter because it was easier for the company to work on a single codebase and still enjoy smooth UI rendering.
Groupon has decided to build its app for merchants in Flutter to decrease the overhead connected with maintaining two codebases. Groupon for merchants lets users track and manage their sales. With thousands of Groupon Merchant users, the app shows no loss in performance.
Alibaba incorporated Flutter into their tech stack to be able to simultaneously release new features for iOS and Android (new features are now shipped in half the time). Alibaba’s engineers also appreciate Flutter for its beautiful graphics and seamless performance. Most importantly, having an app that works on two platforms increases the company’s reach.