Skip to content
MCP server

Port 402 Memory

Persistent memory, inbox and reminders for agents, paid per call in USDC via x402

Runs locallyStatus and history
Pricing
Paid
Platforms
API, CLI
Runs
Locally
Version
1.2.0
Listing updated
3 days ago

About Port 402 Memory

Port 402 Memory is a paid MCP server for knowledge and memory. It runs locally on your machine and is started by your AI client.

Port 402 gives an agent three things it cannot have on its own: memory that survives sessions, a secret inbox that others can post to while it is idle, and an alarm clock that wakes it later. There is no account or API key. Each call is paid in USDC on Base through the x402 protocol, and the paying wallet doubles as your private memory namespace.

Prices are tiny: writes and exports $0.002, reads, lists and deletes $0.001, a reminder $0.005, with a default hard cap of $0.01 per call (PORT402_MAX_USD_PER_CALL). The README estimates $1 of USDC at about 500 writes or 1,000 reads. Quota is 1,000 keys and 5 MB per wallet, and inbox keeps the last 200 messages.

The operator warns that values are stored unencrypted on its server, so sensitive data should be encrypted client-side, and that losing the wallet key makes the memory unreachable. Use a dedicated wallet with a few dollars of USDC. The same service is also available over plain HTTP.

Install

Run in a terminal

claude mcp add port402-memory --env PORT402_PRIVATE_KEY='<PORT402_PRIVATE_KEY>' -- npx -y https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb

Add to claude_desktop_config.json

{
  "mcpServers": {
    "port402-memory": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb"
      ],
      "env": {
        "PORT402_PRIVATE_KEY": "<PORT402_PRIVATE_KEY>"
      }
    }
  }
}

Add to ~/.cursor/mcp.json

{
  "mcpServers": {
    "port402-memory": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb"
      ],
      "env": {
        "PORT402_PRIVATE_KEY": "<PORT402_PRIVATE_KEY>"
      }
    }
  }
}

Add to .vscode/mcp.json

{
  "servers": {
    "port402-memory": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb"
      ],
      "env": {
        "PORT402_PRIVATE_KEY": "<PORT402_PRIVATE_KEY>"
      }
    }
  }
}

Add to ~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "port402-memory": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb"
      ],
      "env": {
        "PORT402_PRIVATE_KEY": "<PORT402_PRIVATE_KEY>"
      }
    }
  }
}

Add to your client's MCP settings (most use this shape)

{
  "mcpServers": {
    "port402-memory": {
      "command": "npx",
      "args": [
        "-y",
        "https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb"
      ],
      "env": {
        "PORT402_PRIVATE_KEY": "<PORT402_PRIVATE_KEY>"
      }
    }
  }
}

Configuration

  • PORT402_PRIVATE_KEYPrivate key of a dedicated Base wallet holding a few USDC. It pays each call and is your private memory namespace.Required
  • PORT402_MAX_USD_PER_CALLSpending cap per call in USD (default 0.01).

Tools this server provides (10)

Taken from the project documentation; the running server may differ.

memory_set
Store a value under a key
memory_get
Read a value, with its updatedAt time
memory_list
List keys
memory_delete
Delete a key
memory_export
Export all memory as a signed document
inbox_get_url
Get the secret inbox URL
inbox_read
Read inbox messages
reminder_schedule
Schedule a reminder
reminder_list
List pending reminders
reminder_cancel
Cancel a reminder

What it does

Wallet-keyed memory
Store, read, list, delete and export JSON values under keys tied to the paying wallet.
Public inbox URL
A secret URL anyone can post to for free; you read it later.
Reminders
Schedule a message from 10 seconds to 366 days out, optionally also POSTed to a webhook.
Signed export
Export memory as a document with sha256 and Ed25519 integrity.
Spending cap
A per-call cap defaults to $0.01.

Good for

  • Give an agent memory that persists between sessions
  • Let webhooks or other agents leave messages for a sleeping agent
  • Have an agent schedule its own follow-up
  • Back up agent memory as a signed export

Pricing

Paid

Pay per call from $0.001 in USDC on Base; no subscription

Prices change. Check port-402-production.up.railway.app before you buy.

Port 402 Memory FAQ

Do I need an API key?

No. Calls are paid in USDC on Base via x402 from a dedicated wallet.

Is memory encrypted?

Values are stored as plain JSON on the operator's server, so encrypt sensitive values first.

What if I lose the wallet key?

Memory becomes unreachable; the service offers a key-rotation migrate call to use beforehand.

How much memory is allowed?

1,000 keys and 5 MB per wallet.

Is Port 402 Memory free?

No. Port 402 Memory is a paid product.

How do I add Port 402 Memory to Claude Code?

Run this command in your terminal: claude mcp add port402-memory --env PORT402_PRIVATE_KEY='<PORT402_PRIVATE_KEY>' -- npx -y https://github.com/Tifdt/port402-memory-mcp/releases/download/v1.2.0/port402-memory.mcpb

What are the best alternatives to Port 402 Memory?

The closest alternatives to Port 402 Memory are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

Alternatives to Port 402 Memory

  1. REA

    MCP server

    CLI and MCP server that lets coding agents reverse engineer apps and binaries

    Runs locally
    • Open source
    • 464K GitHub stars
    • Developer tools
  2. Codebase Memory

    MCP server

    Local MCP server that builds a code knowledge graph for AI coding agents

    Runs locally
    • Open source
    • 48.7K GitHub stars
    • Knowledge and memory
  3. GitHub

    MCP server

    Official MCP server connecting AI assistants to GitHub repos, issues and workflows

    Not checked yet
    • Remote
    • Open source
    • 34.5K GitHub stars
    • Developer tools
  4. MCP toolkit giving coding agents symbol-level code retrieval and editing

    Runs locally
    • Open source
    • 31.5K GitHub stars
    • Developer tools
  5. XERJ

    MCP server

    Local search engine for AI agents with cited answers over your code and docs

    Runs locally
    • Open source
    • 19.2K GitHub stars
    • Knowledge and memory
  6. Ouroboros

    MCP server

    Spec-first layer that pins requirements and verifies results of AI coding agent work

    Runs locally
    • Open source
    • 6.4K GitHub stars
    • Developer tools