Skip to main content
To enable sessions across multiple runs, you need to configure a database. Once configured, Agno automatically stores conversation history, session state, and run metadata. Paused runs persist their status and requirements so they can be continued later.
Database selection, connection strings, credentials management, and operational guidance live in the Database overview. Reuse that setup here—this page only adds the session-specific considerations.

Quick Start

Once you have a db object (Postgres, SQLite, DynamoDB, …) configured per the storage docs, persistence is enabled simply by passing it to your Agent, Team, or Workflow:

Supported Databases

Nothing new lives here—simply reuse the database drivers and guidance from /basics/storage:
  • PostgreSQL (recommended) – Production-grade, supports custom session_table names for isolating workloads.
  • SQLite – Great for local development; swap the file path just as you would elsewhere.
  • InMemoryDb – Useful for tests or demos only. Data disappears when the process exits.
If you need to tune indexing, retention, or connection pools, do that in the shared storage layer so every feature (sessions, memories, knowledge, etc.) benefits from the same configuration.

Session IDs

Sessions are identified by session_id. Use the same ID to continue a conversation:
Need custom naming conventions, caching, or UI-friendly labels? Continue with the Session Management guide.

What Gets Stored

When you configure a database, Agno automatically stores:
  • Messages - User inputs and agent responses
  • Run metadata - Timestamps, token usage, model info
  • Session state - Custom key-value data
  • Tool calls - Tool usage and results (optional)
  • Media - Images, audio, files (optional)
See Storage Control to customize what gets saved.

Multi-User Sessions

Use user_id to track different users:

Session Storage Schema

When you configure a database, Agno stores sessions in a structured format. Here’s what gets saved for each session:
Want to visualize your sessions? Check out the AgentOS UI sessions page for a beautiful interface to view and manage all your conversation threads.

Guides

Now that you have persistence configured, explore what you can do with sessions: