# witcheer's Wingtips #66: sessions.auto_prune

Written by [witcheer](https://x.com/witcheer) at Nous Research. Republished with credit.

Canonical: https://hermeswatcher.com/wingtips/66  
Published: 2026-09-08  
[Original](https://notwitcheer.github.io/hermes-recipes/wingtips/66-sessions-auto-prune/) · [On X](https://x.com/witcheer/status/2097201422844436642) · [Full collection](https://notwitcheer.github.io/hermes-recipes/) · [Official docs](https://hermes-agent.nousresearch.com/docs/user-guide/sessions#automatic-cleanup)

[Source Markdown](https://raw.githubusercontent.com/notwitcheer/hermes-recipes/8653fb699a137a32e81936fa33cabacd3f4f2095/docs/wingtips/66-sessions-auto-prune.md): use this file as the base for relative links in the verbatim text below.

Sources: [Hermes docs: Sessions](https://hermes-agent.nousresearch.com/docs/user-guide/sessions#automatic-cleanup)


Hermes Wingtips #66: sessions.auto_prune

every conversation you have with Hermes Agent is kept, so you can resume it or search it later. over time, a busy gateway or cron setup collects a lot of ended sessions that nobody will open again.

so what happens to them?

Hermes now tidies up for you: sessions that have ended and sat untouched for a long while are removed when Hermes starts, and the database gives the space back when there is enough to reclaim. anything open, pinned or mid-conversation stays put, and your recent history stays searchable.

if you would rather keep every session forever, it is one command:

`hermes config set sessions.auto_prune false`

and if you like the cleanup but want a wider window, `sessions.retention_days`.
