Realm admins control message retention and channel auto-archive at Admin → Settings → Messaging → Retention. Two settings:
Retention days — messages older than this are soft-deleted by a daily job.
0= disabled (keep forever).Auto-archive days — channels with no activity for this long are auto-archived.
0= disabled. Applies to DMs, group DMs, and user-created channels only — area channels are exempt.
Soft delete vs hard delete
Retention is a soft delete — old messages are marked deleted but rows are preserved (with content_plain = NULL and the user's name removed). They're excluded from normal views but visible in admin exports with "Include deleted" enabled. Hard deletion only happens via super-admin GDPR right-to-erasure flows.
Unarchiving auto-archived channels
Note — Channel owners, admins and realm admins can unarchive — not regular members. If a channel matters enough to revive, an owner needs to do it.