Search for SQLite forum software and you will find two kinds of answers: people who assume SQLite is a toy, and people who run large sites on it happily. Both are partly right. SQLite is not a drop-in replacement for a database server under every workload — but for the kind of community most self-hosted forums actually serve, it is often the more reliable choice, not the compromise.

This post explains what SQLite does well for a forum, where it genuinely stops scaling, and how to run and back it up with confidence. bulletinbored supports SQLite as its default backend and MySQL as an option, so we have a stake in this — but the engineering points stand on their own.

What SQLite actually is

SQLite is not a cut-down server. It is a complete, serverless SQL engine stored in a single file. There is no separate process, no port to expose, no user account to secure and no service to keep running. Your application opens the file and talks to it directly.

For a forum, that removes an entire category of operational work:

  • Nothing to install beyond PHP’s PDO extension.
  • Nothing to expose to the network, because there is no database port.
  • Nothing to tune at the server level for a normal workload.
  • Nothing to lose track of, because the whole database is one file.

Why a single file is a good fit for forums

Forums are read-heavy. Most requests read threads, categories and user profiles; writes are comparatively rare and small — a new post, an edit, a login timestamp. That pattern suits SQLite well.

A few practical advantages that matter for a self-hosted community:

Backups become trivial

With MySQL you need a dump tool, credentials and enough disk for a restore. With SQLite, backing up is copying a file. A single-file database is the easiest thing on your server to snapshot, move between hosts or archive off-site.

Portability

Moving hosts is a copy operation, not a migration project. Download the file, upload it elsewhere, point the config at it. No mysqldump, no import step, no version mismatch.

A smaller attack surface

A database server listening on a port is something you must firewall, patch and authenticate. SQLite has no network listener at all. For a small forum, “there is no database service to compromise” is a real security win.

Predictable performance at small and medium scale

With the default rollback journal or, better, WAL mode, reads and writes coexist well. WAL (write-ahead logging) lets readers continue while a write is in progress, which removes the most common concurrency complaint about SQLite.

The honest limits

SQLite is the right default, not a universal answer. Reach for MySQL when:

  • You run multiple application servers. SQLite is a local file; two machines cannot safely share it over a network filesystem. If you scale horizontally, you need a database server.
  • You have very high write concurrency. Writes are serialised. A forum with a constant flood of simultaneous posts from thousands of users will eventually feel it.
  • Your host requires a managed database. Some platforms only offer MySQL/PostgreSQL and give you no writable persistent filesystem.

Most small and medium forums never hit those conditions. Be honest about which one you are building before you decide.

SQLite vs MySQL for a forum

Concern SQLite MySQL/MariaDB
Installation PHP extension only Separate server + service
Network exposure None Port to secure and firewall
Backup Copy one file Dump + restore procedure
Moving hosts Copy the file Export/import
Concurrent writes Serialised (WAL helps) Designed for concurrency
Multiple app servers Not supported Supported
Operational tuning Minimal Users, buffers, connections

Running SQLite well

A few settings and habits make a real difference:

  • Enable WAL mode. It improves read/write concurrency and is the single best default change for a busy forum.
  • Set a busy timeout. When a write is in progress, wait instead of failing immediately; a few seconds of patience avoids spurious “database is locked” errors.
  • Keep the database on local disk. Not on a network mount, not on a synced folder.
  • Store it outside the web root. The file should never be downloadable.
  • Back it up consistently. Use SQLite’s own backup mechanism rather than copying a file mid-write.

The last point is worth repeating: copying a live database file while a write is in flight can capture an inconsistent state. Use the online backup command or a proper snapshot. We cover the full procedure in how to back up and restore a self-hosted forum.

Is SQLite “real” enough for production?

Yes — with the caveat that “production” means your workload, not someone else’s. SQLite is used in phones, browsers, embedded systems and a long list of web applications. The question is never “is SQLite production-grade?” but “does my access pattern fit a local, serialised-write database?” For most forums, it does.

And it has a quieter advantage that is easy to undervalue: fewer moving parts means fewer things to get wrong at 2 a.m. A forum that is simple to understand is a forum you will still be running in five years.

Where bulletinbored fits

bulletinbored defaults to SQLite and also supports MySQL. It needs only PHP 8.1+ with PDO — no database server, no Composer, no Docker. With SQLite, the whole installation is files on disk: a config, an uploads directory and one database file.

If your community is small or medium and you control the server, SQLite is not the compromise. It is the sensible default.