Lorixen.
EN

Is SQLite enough for your small business app?

Short answer: For many small business apps and websites, SQLite is enough: a booking tool, an internal dashboard, a catalogue site or a small customer portal running on one server. The SQLite team itself says it works well for most low to medium traffic websites. It stops being the right choice when many processes must write at the same instant, when several servers need to share one database, or when the file would sit on a network drive. Turn on WAL mode, plan backups, and you'll know early if you outgrow it.

Why the question comes up

Developers often reach for PostgreSQL or MySQL by default, which means running, securing, patching and backing up a separate database server. For a small app that handles a few hundred orders a week, that can be more infrastructure than the app itself. SQLite is a library: the whole database is one file, the app reads and writes it directly, and there's no server to manage.

The question is whether that simplicity will bite you later. The honest answer depends on a few specific things about your app, not on how "serious" it feels.

What the SQLite documentation says

SQLite publishes its own guide to appropriate uses, which is refreshingly direct. A few points matter most for business apps:

  • Websites: it describes SQLite as working well as the database engine for most low to medium traffic websites.
  • Readers and writers: SQLite supports an unlimited number of simultaneous readers but allows only one writer at any instant. For many situations that's fine, because writes are quick and queue up.
  • Many concurrent writers: if many threads or processes need to write at the same instant and can't queue and take turns, the guide says to choose a client/server database.
  • Data across a network: if the data is separated from the application by a network, it recommends a client/server engine instead.

Signs SQLite will suit you

  • One server runs the app. The database file sits on that server's local disk.
  • Writes are short and modest in number. Saving a booking, updating a profile, recording an order.
  • Reads dominate. Catalogue pages, reports and dashboards read far more often than they write.
  • The dataset fits comfortably on one disk. Most small business data does.
  • You value simple operations. Copying one file is a lot easier than managing a database server.

Signs you need a database server

  • Several app servers behind a load balancer need the same data.
  • Heavy simultaneous writing, such as many background workers updating rows constantly, or a high-volume event log.
  • A network file share. SQLite's documentation on WAL mode notes that all processes must be on the same host and that WAL does not work over a network filesystem.
  • Fine-grained database users and permissions, such as giving a reporting tool read-only access to some tables.
  • Features you rely on that SQLite handles differently or doesn't have, for example certain data types or extensions your team already uses.

Settings that make SQLite production-ready

Turn on WAL mode. Write-ahead logging changes how SQLite records changes. Its documentation says WAL provides more concurrency because readers do not block writers and a writer does not block readers. For web apps, this is usually the single most useful setting.

Set a busy timeout. When a write is in progress, another writer waits. Without a timeout, your app may get an immediate "database is locked" error instead of waiting a moment. Most drivers let you set this in the connection options.

Keep transactions short. Don't hold a write transaction open while calling an external API or rendering a page. Collect the data first, then write quickly.

Use one connection setup everywhere. Make sure every process opens the database with the same settings, including foreign key enforcement, which SQLite leaves off by default for compatibility.

Backups

A running SQLite database shouldn't be backed up by simply copying the file while it's being written, because you may catch it mid-change. Use SQLite's own backup command or API, or a tool built for SQLite that streams changes to object storage. Test restoring the backup somewhere else, just as you would with any database.

Because the database is one file, moving to a new server is easy: stop the app, take a clean backup, copy it, start the app on the new server.

Planning an exit, just in case

If you think you might outgrow SQLite, keep your options open:

  • Use an ORM or query builder that supports both SQLite and PostgreSQL.
  • Avoid SQLite-only quirks in your queries where possible.
  • Keep migrations in code, so the schema can be recreated on another engine.

Moving later is real work but manageable when the schema is tidy and the app talks to the database through one layer.

A worked example

Take a hypothetical Bristol bike repair shop with a booking app built for its two workshops. The app runs on a single small cloud server, handles a few dozen bookings a day and shows staff a daily job list. The developer chose SQLite with WAL mode and a busy timeout, scheduled a nightly backup to object storage using SQLite's backup command, and tested a restore on a laptop. When the owner asked about adding a third workshop, the developer checked the write load and found no reason to change: still one server, still short writes.

FAQ

Is SQLite only for prototypes?

No. It's used in production in a huge range of software. The question is fit, not seriousness.

Can I run SQLite in Docker?

Yes, as long as the database file lives on a persistent volume on the same host, not inside the container's temporary filesystem.

What about hosting platforms that run several app instances?

If the platform runs multiple instances that can't share a local disk, SQLite isn't a good fit there without a replication tool designed for it.

Will a busy timeout fix "database is locked" errors?

It helps with brief contention. Frequent locking usually means long transactions or more concurrent writing than SQLite suits.

If you're deciding on a database for a new business app, tell us what the app needs to do and we'll give you a straight recommendation.

Sources

WhatsAppBook a call