Plan your custom software project with precision Estimate Now!
Flutter

What Is Flutter? Definition, Dart, Widgets, Architecture and Tools

Tuhin Bhatt

Co-founder of Intelivita

Published on January 1, 2024
8 min read
What is Flutter?

What Is Flutter?

Flutter is Google’s open-source UI toolkit for building natively compiled apps for iOS, Android, web, Windows, macOS and Linux from one codebase. Developers write Flutter apps in the Dart programming language, and Flutter draws every pixel of the interface itself instead of using each platform’s native UI controls.

One codebase means one team writes, tests and maintains the app for every platform, and it replaces 2 separate native codebases for an iOS and an Android app. Production examples are listed in 15 Amazing Apps Built with Flutter Framework.

Flutter differs from a hybrid framework. A hybrid app runs web code inside a WebView, while Flutter compiles Dart to machine code for mobile and desktop.

What Programming Language Does Flutter Use?

Flutter uses Dart, a client-optimized programming language developed by Google. Developers write the whole Flutter app in Dart, including the interface, the business logic and the network calls, so one language covers every platform the app targets.

Why Does Flutter Use Dart?

Flutter uses Dart because Dart compiles in 2 modes. During development, the Dart VM compiles code just in time (JIT), which powers hot reload: a code change appears in the running app without a restart and without losing the app’s current state. For release, Dart compiles ahead of time (AOT) to native machine code for mobile and desktop, and to JavaScript or WebAssembly for the web (Dart overview).

Dart also has sound null safety. A value cannot be null unless the code declares it nullable, so the compiler catches null errors before the app ships.

Which Other Languages Work With Flutter?

Flutter apps call platform code written in 4 other languages: Kotlin and Java on Android, and Swift and Objective-C on iOS. Flutter connects Dart to that code through platform channels, which pass messages between the Dart side and the native side. Apps use platform channels for device features without a ready-made Flutter plugin. Dart also calls C and C++ libraries directly through dart:ffi.

Which Tools Are Used to Build Flutter Apps?

Flutter apps are built with the Flutter SDK, an editor with the official Flutter plugin, and Flutter DevTools for debugging. iOS builds also require Xcode on a Mac. The SDK includes the Dart compiler, the widget libraries and the flutter command-line tool.

Which IDE Is Best for Flutter?

Flutter supports 3 editors officially: Visual Studio Code, Android Studio and IntelliJ IDEA. Each one adds code completion, widget editing, hot reload and debugging through the Flutter and Dart plugins.

  • Visual Studio Code suits developers who want a light, fast editor.
  • Android Studio suits developers who need the Android emulator and Android build tools in the same window.
  • IntelliJ IDEA suits teams that already use JetBrains editors for other languages.

Which Other Tools Support Flutter Development?

Flutter projects use 5 types of supporting tools:

  • Flutter DevTools profiles performance, inspects the widget tree and tracks memory (DevTools).
  • DartPad runs Dart and Flutter code in the browser, with no installation.
  • Firebase provides authentication, a database, push notifications and analytics through official Flutter plugins.
  • Codemagic and Bitrise build, test and publish Flutter apps automatically (CI/CD).
  • pub.dev hosts the packages and plugins Flutter apps add for payments, maps, cameras and other features.

How Does Flutter Build an App’s Screens?

Flutter builds every screen from widgets, and its engine draws those widgets directly on the display. A widget describes one part of the interface, such as a button, a row of text or a whole page, and Flutter combines widgets into a tree that forms the screen.

What Are Flutter Widgets?

Flutter widgets are the building blocks of every Flutter interface, and they come in 2 types:

  • Stateless widgets display content that does not change after it appears, such as a label or an icon.
  • Stateful widgets hold data that changes, such as a form, a counter or an animation, and rebuild when that data changes.

Flutter ships with layout widgets (Row, Column, ListView, GridView), input widgets (buttons, text fields, gesture detectors) and styling widgets. The full list is in the Flutter widget catalog.

What Is the Architecture of Flutter?

Flutter is a layered system of 3 layers, and each layer depends only on the one below it (Flutter architectural overview):

  1. Framework, written in Dart: the widgets, layout, animation and gesture libraries the developer works with.
  2. Engine, written in C++: draws each frame, lays out text and runs the Dart runtime. Since Flutter 3.27, its default renderer on iOS and on Android API 29+ is Impeller, which compiles its shaders when the engine is built, so they do not compile while the app runs.
  3. Embedder, specific to each platform: starts the app, connects it to the operating system and hands it input events.

To the operating system, a Flutter app is packaged the same way as any other native app.

How Is a Flutter App’s Code Structured?

A Flutter app’s code is structured in 2 layers: a UI layer of widgets and view models, and a data layer of repositories and services that fetch and store data, as Google’s Flutter architecture guide recommends. A state management approach, such as BLoC, Riverpod or Provider, moves data between the 2 layers.

How Is a Flutter App’s UI Designed?

A Flutter app’s UI is designed with Material Design widgets for an Android-style look, Cupertino widgets for an iOS-style look, or a custom design system that looks the same on both. Because Flutter draws its own interface, a custom design renders identically on every device.

Flutter supports design work in 4 ways:

  • Material 3 components, themes and color schemes are built in (Material Design for Flutter).
  • Hot reload shows a layout, color or spacing change in the running app without a restart, so designers and developers review changes together.
  • Responsive layout widgets adapt one screen to phones, tablets, desktop windows and browsers.
  • Accessibility support exposes labels to screen readers through the Semantics widget and respects the user’s text size setting.

Intelivita prices UX/UI design and prototype at $5,000–$25,000, one-off, as part of Flutter App Development Company projects.

What Are the Best Practices for Flutter Development?

Flutter development best practices keep an app fast and its code maintainable. Google’s performance best practices and architecture guide set 6 core rules:

  1. Use const constructors for widgets that never change, so Flutter skips rebuilding them.
  2. Keep build methods small and free of slow work, and split large widgets into smaller ones.
  3. Separate UI code from business logic, with the UI layer and data layer described above.
  4. Choose one state management approach per app and apply it everywhere.
  5. Write 3 levels of tests: unit tests for logic, widget tests for screens and integration tests for whole user journeys (Testing Flutter apps).
  6. Enforce lint rules with the flutter_lints package, so every developer follows the same Dart style.

How Is a Flutter App Built and Released?

A Flutter app is built and released in 6 steps, from SDK setup to app store submission:

  1. Set up the Flutter SDK and an editor, plus Xcode on a Mac for iOS.
  2. Create the project with the flutter create command.
  3. Build the screens from widgets, checking each change with hot reload.
  4. Test the app with unit, widget and integration tests on real iOS and Android devices.
  5. Build the release: an app bundle for Google Play (Android release guide) and an IPA for the App Store (iOS release guide).
  6. Submit the app through Google Play Console and App Store Connect for review.

A business that wants to test the idea first starts with an MVP of one core journey. Intelivita’s MVP Development Services start from $10,000 and take 4–8 weeks.

Which Platforms Does Flutter Support?

Flutter supports 6 deployment platforms: Android, iOS, web, Windows, macOS and Linux. As of Flutter 3.50, the Flutter team supports Android API 24 and later and iOS 15 and later (supported deployment platforms).

Mobile is Flutter’s main use, and web and desktop builds come from the same Dart code. Each new Flutter release changes these minimum versions, so the supported-platforms page is the current reference.

When Should a Business Choose Flutter Over Other Frameworks?

A business chooses Flutter when it needs one app on iOS and Android with a custom design that looks the same on both. A business chooses a native language when the app depends on platform features the day Apple or Google releases them.

Comparison Flutter Alternative
Flutter vs. React Native Dart; draws its own UI JavaScript or TypeScript; renders native UI components
Flutter vs Kotlin One codebase for iOS and Android Kotlin builds native Android apps; Kotlin Multiplatform shares logic across platforms
Flutter vs Swift One codebase for iOS and Android Swift builds native iOS apps only
Flutter vs. Ionic Compiles to machine code HTML, CSS and JavaScript running in a WebView

The cost of a Flutter build depends on its scope, and How Much Does It Cost to Make a Flutter App for Your Business? breaks it down by app type. To plan a Flutter app with a team that builds them, start with a free consultation and quote from a Flutter App Development Company.

Get Notified!

    Contact Us for Project Discussion

    Ready to take the first step towards turning your software dreams into reality? Contact us today to schedule a project discussion. Our team of experts is eager to hear your ideas and provide tailored solutions to meet your unique needs.








      Photo of Tuhin Bhatt
      Request a Call Back

      Enter your contact details and one of our friendly team member will be in touch soon!


        Get a Free Consultation in 24 Hours