Skip to main content
doc0blade47/mem0documentation home
Sign in

Quickstart Overview

Last updated Oct 11, 2026100% grounded

Overview

Mem0 gives your AI agents and applications persistent, intelligent long-term memory. It automatically extracts, stores, updates, and searches memories across chat sessions so your AI can remember user preferences, facts, and past decisions over time.

To get started, you can choose between three distinct ways to run Mem0 depending on your privacy, setup complexity, and infrastructure needs:

  • Mem0 Platform (Cloud): A fully managed cloud service hosted by Mem0. The easiest way to get started with zero infrastructure to maintain.
  • Local Library: Run Mem0 directly inside your application or local script, storing data locally on your machine.
  • Self-Hosted Server: Run your own private Mem0 server using Docker or local infrastructure for complete data control.

Choosing Your Deployment Mode

Review the comparison table below to decide which setup fits your workflow.

ModeBest ForSetup ComplexityInfrastructure
PlatformQuick testing, cloud apps, zero maintenanceLow (Minutes)Fully Managed Cloud
Local LibraryLocal scripts, offline use, privacy-first prototypingLowLocal Storage
Self-Hosted ServerProduction deployments requiring complete data privacyMediumDocker / Custom Server

Getting Started

Installation and Setup Wizard

Follow these steps to set up Mem0 using the interactive setup wizard or your preferred deployment approach.

  1. Install the CLI or Library: Depending on your environment, install the Mem0 command-line tools or python/node libraries. For instance, run the interactive setup command:
    mem0 init
  2. Choose Your Deployment Mode: When you run the setup wizard, you will be prompted to select how you want to use Mem0:
    • Platform (Recommended): Hosted memory managed by Mem0. You can authenticate either by logging in with your email (receiving a verification code) or by entering your API key manually.
    • Open Source / Self-Hosted: Run your own open-source stack by selecting your preferred language model (LLM), embedder, and vector store providers.
  3. Configure Your Environment: If you are using the cloud platform, you will need to make your API key available to your application by setting the environment variable:
    export MEM0_API_KEY="your-api-key-here"
    If you are running a self-hosted server, point your application to your server URL using:
    export MEM0_HOST="http://localhost:8888"

Note

You can get your Mem0 Platform API key directly from your account dashboard on the web if you prefer manual entry over email authentication.


Key Concepts

To use Mem0 effectively, it helps to understand a few core concepts:

  • Memory Search: Semantic retrieval that finds relevant facts based on meaning rather than exact keyword matches.
  • Auto-Capture & Extraction: The ability to automatically scan conversation turns, distill lasting facts, and de-duplicate them on the storage backend.
  • Namespaces & Scoping: Organizing memories using identifiers (such as user IDs or agent IDs) so different users and AI agents have isolated memory spaces.

Tips and Warnings

Tip

For multi-part or complex questions, perform multiple searches with varying search queries or angles to ensure your agent gathers every relevant piece of background history.

Warning

If you configure a self-hosted server, make sure your environment variables (such as MEM0_HOST) do not conflict with your platform mode settings, or your application may route requests to the wrong endpoint.

Was this page helpful?