WAL (Write-Ahead Logging) writes changes to a log before they are applied to data files. After a crash, Postgres replays WAL to recover. Replication can ship WAL to replicas so they apply the same changes in the same order.