Skip to main content
Adding a database persists runs under a session_id. Agent and team sessions contain conversation runs. Workflow sessions contain workflow runs.

Configure the Session Table

By default, sessions are stored in the agno_sessions table. The table is created automatically if it doesn’t exist. Use session_table to store sessions in a custom table:
Use separate tables when you need database-level isolation between environments.

What Gets Stored

Each session record contains:

Retrieve Sessions

Use get_session() to retrieve a stored session:

Works With Teams and Workflows

Teams and workflows expose the same get_session() interface:
Workflow sessions store complete pipeline runs rather than conversation messages. See Workflow Sessions for details.

Next Steps

Session Summaries

Condense long conversations to save tokens.

Storage Control

Choose what gets persisted to your database.

Developer Resources