What is SQLite?

In this article, we'll give a brief introduction to what SQLite is.

Introduction to SQLite

What is SQLite?

SQLite is a lightweight relational database management system (RDBMS) that is in the public domain and free for anyone to use.

Here are some of its key characteristics:

  • Unlike client-server systems such as Oracle, SQL Server, or MySQL, SQLite is self-contained in a single database file.
  • It is cross-platform and runs in many environments. Since everything is contained in the SQLite file, there is no need for additional database server configuration.
  • It is lightweight and fast, making it a popular choice to embed directly into applications. SQLite is widely used in IoT devices and mobile apps.
  • It supports most standard SQL features.

When developing iOS apps, there are multiple options for data storage. SQLite is particularly useful when you need to store relatively large amounts of data or perform queries to extract specific information.


When Should You Use SQLite?

Earlier we mentioned “relatively large amounts of data,” but this refers only to the scale of data stored locally on a device.

If you need to handle truly large-scale datasets, SQLite may not be sufficient. In such cases, it's better to use a client-server type RDBMS over the network.


For example, in a recent enterprise iOS app I developed, the main database was SQL Server. Since users needed the app to work offline, we fetched only the necessary data over the network and stored it in SQLite. This way, the app could function offline while still syncing with the central database.

Like this, SQLite is often used as a cache for enterprise RDBMS systems.

While this may not be a concern for typical iOS apps, generally SQLite is not recommended for use cases involving big data or heavy concurrent writes.


This was a brief introduction to SQLite.