SQLite’s Write-Ahead Log and shared-memory files retain earlier database pages, letting you recover data the live DB no longer shows.
How it works
db-walcontains committed frames not yet checkpointed;db-shmis the index.- A row truncated or overwritten in the main DB can still be fully present in the WAL.
- Dump all pages / all frames (
sqlite3,sqlite-forensic, or manual WAL parsing) and diff revisions.
Detection & defence
- For sensitive data, checkpoint +
VACUUMand usePRAGMA secure_delete=ON. - Understand that a mobile app’s private DB is only as private as the device.

