Emadelddin Juha
2 min readJun 12, 2022

--

Database for Flutter Application

How to choose the right database for your Flutter application
this article helps you find the best persistent database solution to your application

First you find a two types from Database relational and not relational

database

With flutter platform, you can achieve the relational databases with two approaches:

relational database

1- Pure

2- Entity

The first one you need hard coding, but the controller is higher, For entity no need more code but the controller is less than previously.

What’s about the implementation?

Flutter is provided by sqlflite implement SQLite database to store data. You can look and use a package from here.

when your choice a pure you will write all queries by hand

For entity, you will find two ORM candidates, Moor and Floor.

and for Non-relational databases like MongoDB and firebase

non-relational database

For Non-relational databases, you can use firebase or mongo_dart and connect to the database. mongo_dart Server-side driver library for MongoDB implemented in pure Dart but if you already have a Nodejs backend, then expose REST API and connect with Flutter using http or other similar packages, the connecting frontend directly to database is bad.

For more information, you can visit:

--

--