---
source: https://iinventedlight.com/library/notes/sqlite-wal-mode.md
title: "SQLite WAL mode: faster, more concurrent writes"
license: CC-BY-4.0
license_url: https://creativecommons.org/licenses/by/4.0/
source_license: "Public domain (sqlite.org); restated in our own words"
attribution: "Summary by iinventedlight (AI-assisted). Sources: SQLite (sqlite.org), Write-Ahead Logging, Public domain (sqlite.org); SQLite (sqlite.org), Atomic Commit In SQLite, Public domain (sqlite.org)."
author: "iinventedlight (synthesis of cited sources); text drafted with AI assistance"
date: 2026-11-04
status: published
checked_on: 2026-11-05
as_of: 2026-11-05
confidence: medium
untested: "No code was run; only the fetched documentation pages were read."
category: coding-references
topic_area: "sqlite: performance"
tags: sqlite, wal, concurrency, performance
sources:
  - id: S1
    title: "Write-Ahead Logging"
    publisher: SQLite (sqlite.org)
    url: https://www.sqlite.org/wal.html
    accessed: 2026-11-05
    license: "Public domain (sqlite.org)"
  - id: S2
    title: "Atomic Commit In SQLite"
    publisher: SQLite (sqlite.org)
    url: https://www.sqlite.org/atomiccommit.html
    accessed: 2026-11-05
    license: "Public domain (sqlite.org)"
    license: "Public domain (sqlite.org)"
---
# SQLite WAL mode

## Short answer
`PRAGMA journal_mode=WAL;` switches a database to write-ahead logging. Readers and a writer usually do not block each other, and many workloads get faster. The choice is stored in the database file. [S1]

## Caveats
- All clients must share one host; WAL is not for network filesystems. [S1]
- Writers append to a `-wal` file; checkpoints copy changes back. [S1]
- Atomic commit still works with WAL, via a different mechanism than the classic rollback journal. [S2]

## Claims
- id: C1
  claim: WAL is significantly faster in most scenarios.
  source: S1
  evidence: "WAL is significantly faster in most scenarios"
- id: C2
  claim: In WAL, readers and writers do not block each other.
  source: S1
  evidence: "readers do not block writers and a writer does not block readers"
- id: C3
  claim: WAL does not work over a network filesystem.
  source: S1
  evidence: "WAL does not work over a network filesystem"
- id: C4
  claim: Atomic commit still works when write-ahead logging is enabled.
  source: S2
  evidence: "SQLite still supports atomic commit when write-ahead logging is enabled"

## Sources
- [S1] Write-Ahead Logging. SQLite (sqlite.org). https://www.sqlite.org/wal.html . License: Public domain (sqlite.org). Accessed 2026-11-05.
- [S2] Atomic Commit In SQLite. SQLite (sqlite.org). https://www.sqlite.org/atomiccommit.html . License: Public domain (sqlite.org). Accessed 2026-11-05.

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted).

Source notice: SQLite documentation is dedicated to the public domain (https://www.sqlite.org/copyright.html).
