Mobile Azərbaycanca oxu →

Flutter or native: when does one codebase for two platforms pay off

Write the code once and run it on both iPhone and Android. That's Flutter's promise. But is it the right choice for every project? When to go Flutter, when native, and when you don't need an app at all.

Nail Seyidov
Founder of NS Studio · 3 min read
Flutter or native: when does one codebase for two platforms pay off

Photo: Amanz / Unsplash

In 2020 I wrote about the question “Website or mobile app?”. Once you've decided you need an app, the next question comes: how do we build it? Separately for each platform, or with one codebase for both?

I work with Flutter myself, but in this post I won't recommend it for every project. Let's look at the differences.

What native is, and what Flutter is

Native means an app built with each platform's own language and tools: Swift for iOS, Kotlin for Android. You end up with two separate apps, two separate codebases and often two separate teams.

Flutter is Google's open-source toolkit. One codebase written in Dart produces both an iOS and an Android app. If you want, you can build web and desktop versions from the same code as well. It isn't the only tool in this space — there are alternatives like React Native — but the approach is the same: one codebase, several platforms.

Flutter's strengths

  • One codebase, one team. A feature is written once and a bug is fixed once. That has a direct effect on both the budget and the timeline.
  • The same look. The app looks and behaves the same on both platforms. That matters for a brand.
  • Fast development. Seeing a change on screen instantly speeds up interface work a lot.
  • Performance that's good enough. In most business apps — a store, orders, bookings, a personal account — users don't feel any difference.

Its limits

  • App size is somewhat larger than a native app.
  • New platform features sometimes arrive with a delay or require native code.
  • Dependence on plugins. Some device features need a ready-made plugin; if the plugin is poorly maintained, the problem becomes yours.
  • The platform's “feel”. iOS and Android users are used to different behaviours. You can do that in Flutter too, but it takes extra attention.

When native is better

  • Heavy graphics, games, augmented reality.
  • Deep device features: Bluetooth hardware, constant background work, health sensors.
  • When only one platform is the target — then the “two platforms” advantage disappears.
  • When the company already has separate iOS and Android teams.

Maybe you don't need an app?

For content, a catalogue, a simple form or bookings, a well-built mobile site or a PWA is often enough: nothing to install, no store review to wait for, and it shows up in search. I covered this in detail in “Is PWA the end of mobile apps?”. An app only makes sense when the user finds a reason to keep it on their phone.

6 questions to decide

  1. Which platform are your users on? If they're on both, Flutter is a strong candidate.
  2. Which device features do you need? If the list is long and specialised, look at native.
  3. Can the budget cover two separate teams?
  4. How soon do you need to launch? If speed matters, one codebase wins.
  5. Does the app need to work offline? It's possible either way, but it has to be planned in advance.
  6. Who will maintain it in two years? It should be easy to find developers for the technology you choose.

The bottom line

For most startup and business apps, Flutter is a smart start: one codebase, one team, two platforms. But “everyone uses it” isn't an argument. The argument is your users and your app's requirements.

I wrote about how small to keep the first version in “MVP: how to build a first version that fits into 6 weeks”. If you're torn between web, mobile and a PWA, let's decide together in mentorship.

On this topic

Keep reading

All posts →
Web Design 2 min read

5 tips for making money with programming

Making money with programming is every developer's wish. Lately we hear the term freelance a lot. But this way of working still isn't widespread in Azerbaijan, while around the world many people…

Mobile 1 min read

ClubHouse can now be downloaded for Android

The Android version of ClubHouse can now be downloaded. In a short time, the ClubHouse platform became one of the most famous social networks in the world. Its difficult sign-up process made people even more…

Mobile 3 min read

Which VPN is the safest and free?

Because of the current situation, VPN use is widespread in Azerbaijan. So many people look for a free VPN and come across all sorts of options. Some of the free VPN options carry a big…