Skip to main content

Reddit MCP server — access Reddit data through MCP protocol

Project description

reddit-mcp

Reddit MCP server — access Reddit data (posts, comments, search) through the MCP protocol.

Quick Start

# 1. Full setup (OAuth login + Reddit cookies)
uvx --from 5mghost-rover reddit-mcp setup

# 2. Add to your AI client config (Claude Desktop, Cursor, etc.)
{
  "mcpServers": {
    "reddit": {
      "command": "uvx",
      "args": ["--from", "5mghost-rover", "reddit-mcp", "serve"],
      "env": {
        "REDDIT_MCP_TOKEN": "pat_xxx"
      }
    }
  }
}

Authentication

reddit-mcp uses two layers of authentication:

  1. PAT / OAuth token — Controls access to the MCP service (shared account system with yt-mcp / x-mcp)
  2. Reddit cookies — Used to fetch data from Reddit's JSON API

PAT Setup (Simplest)

  1. Visit https://mkterswingman.com/pat/login
  2. Log in and generate a PAT
  3. Set REDDIT_MCP_TOKEN=pat_xxx in your MCP config's env
  4. Run uvx --from 5mghost-rover reddit-mcp setup-cookies to set up Reddit cookies

OAuth Setup (Full)

uvx --from 5mghost-rover reddit-mcp setup

This runs the OAuth flow and cookie setup in one step.

CLI Commands

Command Description
reddit-mcp serve Start MCP server (stdio transport)
reddit-mcp setup Full setup: OAuth login + cookie setup
reddit-mcp setup-cookies Cookie-only setup (already have a PAT)
reddit-mcp uninstall Remove MCP registrations and local ~/.reddit-mcp config
reddit-mcp update Check for updates and install latest version
reddit-mcp check Check token & cookie status
reddit-mcp version Show version

MCP Tools

Data Tools

  • get_subreddit_posts — Get posts from a subreddit (hot/new/top/rising, up to 100 per request)
  • get_post_content — Get a post's content and comment tree
  • search_reddit — Search Reddit posts (global or within a subreddit)
  • get_subreddit_info — Get subreddit metadata (subscribers, description, etc.)

Management Tools

  • check_cookies — Check cookie validity, age, and username
  • get_rate_limit_status — Check remaining API quota

Rate Limits

Reddit allows 100 requests per 10-minute window. The client automatically:

  • Reads x-ratelimit-* headers from responses
  • Throttles when remaining quota < 20
  • Retries on 429 (Too Many Requests)

For typical usage (1-10 requests per conversation), you'll never hit the limit.

Cookie Management

Reddit cookies are stored at ~/.reddit-mcp/cookies.json (permissions: 600).

  • Cookies are obtained by launching Chrome and having you log in to Reddit
  • They're stored locally and never uploaded to any server
  • If cookies expire (403 errors), run reddit-mcp setup-cookies to refresh
  • A warning is shown when cookies are > 7 days old

Package Naming

The published PyPI package name is 5mghost-rover, and the installed executable is reddit-mcp.

  • uvx --from 5mghost-rover reddit-mcp ... works for one-off runs
  • pip install 5mghost-rover installs the reddit-mcp command globally

Requirements

  • Python 3.10+
  • Chrome browser (for setup / setup-cookies commands)
  • A valid PAT or OAuth token

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

5mghost_rover-0.0.3.tar.gz (25.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

5mghost_rover-0.0.3-py3-none-any.whl (25.0 kB view details)

Uploaded Python 3

File details

Details for the file 5mghost_rover-0.0.3.tar.gz.

File metadata

  • Download URL: 5mghost_rover-0.0.3.tar.gz
  • Upload date:
  • Size: 25.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for 5mghost_rover-0.0.3.tar.gz
Algorithm Hash digest
SHA256 7d4d5a30429a746867314e99710aebe24d567bec93f96133a0d7d5681781dc68
MD5 8d8ea2c9087dac51b8d3677b5cc24a1a
BLAKE2b-256 431926946c06c15a8b5daa4dceed76f807129aea42a794dcf7c59a3540406294

See more details on using hashes here.

File details

Details for the file 5mghost_rover-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: 5mghost_rover-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 25.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for 5mghost_rover-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 9c5ec98cdb64c2b5a0560dc44b17bc03df27182aabd3c922b38560bc56f6eeb4
MD5 222efc8d259a8a9b569b208e6caa9136
BLAKE2b-256 009b8775a08d80bce758e0707771e70ebf5905ddfc7375f6a9204359e1adebf9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page