Interactive Leetcode MCP logo

Interactive Leetcode MCP

Practice LeetCode with guided hints, local tests, authenticated submissions, problem data, and progress tracking.

Install Interactive Leetcode MCP

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "interactive-leetcode-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@sperekrestova/interactive-leetcode-mcp@latest"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Claude Code command
claude mcp add --transport stdio interactive-leetcode-mcp -- npx -y @sperekrestova/interactive-leetcode-mcp@latest

Run in your terminal. Add --scope project to share it with your team through .mcp.json.

We couldn’t confirm it starts correctly

We hit an unexpected error while testing this listing automatically.

npx -y @sperekrestova/interactive-leetcode-mcp@latest

Rate limit exceeded, please try again later - you have reached the maximum number of concurrent E2B sandboxes (20). If you need more, please visit 'https://e2b.dev/docs/billing'

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked .

Overview

interactive-leetcode-mcp MCP server connects an AI coding workflow to LeetCode for problem practice, authentication, hints, testing, submissions, and account data. It runs over stdio and can be launched with the npm package or a local build. Use it when you want an agent to guide problem solving, run sample tests locally, submit code, and review results. Node.js 20 or newer and a LeetCode account are required for actual use.

Use cases

  • Practice LeetCode problems with progressive hints
  • Run sample tests against local code
  • Submit solutions and inspect runtime results
  • Review submission history and contest rankings

Key features

  • LeetCode authentication and credential status
  • Problem search, lookup, and daily challenge access
  • Progressive hints and tracked practice sessions
  • Local sample-test execution
  • Authenticated solution submission
  • User progress and submission reporting

Tools24

What Interactive Leetcode MCP lets your agent do. Expand a tool for its parameters.

Verified live~3.8k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

15/19 checks healthy over the last 117d

What it can do

From the 24 tools this server returned when we ran it.

Runs commands · 2Handles credentials · 3Makes network requests · 2Read-only tools · 22
Network at startup3 connections
Files written at startupNone
Install scriptsprepare
npm provenanceSigned build
Package age270 days
Maintainers1

Observed 2026-10-22 in an isolated sandbox. A description of reach, not a security audit.

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 11d ago via OSV.dev · @sperekrestova/interactive-leetcode-mcp@latest (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars12Stargazers on the source repository.
npm downloads387Package downloads in the last 30 days.
Last commit2mo agoMost recent push to the default branch.
Install checkInconclusiveWe hit an unexpected error running the automated check.
Tools exposed24Callable tools this server registers over MCP.
Directory activity2 viewsConfig copies, upvotes, and views on AllMCPs.

How Interactive Leetcode MCP works

What interactive-leetcode-mcp MCP server does

The interactive-leetcode-mcp MCP server connects an MCP-compatible client with LeetCode practice workflows. It can retrieve the daily challenge, search problems, fetch problem descriptions, and start a tracked practice session. The session supports progressive hints and can unlock community or editorial solution content after the configured hint progression.

Authentication uses LeetCode cookie values. The agent can initiate the login guidance, accept csrftoken and LEETCODE_SESSION values, validate them with a test API request, and save them for later use. Authentication status includes the username and credential age, with a warning when credentials may be nearing expiration.

How it works

The interactive-leetcode-mcp MCP server is intended for conversational practice. An agent can load the usage guide, obtain a problem, open or resume a session, and help the user work through the problem with hints. The learning flow emphasizes understanding the problem, planning an approach, implementing it, checking complexity, and reviewing the result.

For local validation, the server checks which supported language runtimes are available and runs code against sample cases in a local subprocess sandbox. For remote evaluation, it submits code to LeetCode and returns acceptance status, runtime, memory use, or a failed test case. Supported language examples include Java, Python, C++, JavaScript, and TypeScript.

Setup and configuration

Install the published package globally with npm, run it through npx, or build it from source. The documented runtime prerequisite is Node.js 20.x or newer. A browser is needed for the interactive login process, and a LeetCode account is required for authenticated features.

Claude Code can register the server with its CLI using the stdio transport. Claude Code and Claude Desktop can also load an MCP configuration that starts npx with the package, or starts Node against a locally built build/index.js file. The repository recommends a clean package smoke test for checking installation and CLI availability; completing the MCP handshake requires a separate stdio integration test.

Tools and capabilities

The interactive-leetcode-mcp MCP server provides tools for:

  • Authentication and credential status.
  • Daily challenges, problem lookup, filtering, and pagination.
  • Practice sessions, hint progression, session state, and resets.
  • Local runtime checks and sample-test execution.
  • Community or editorial solution listing and retrieval after hint unlock.
  • Code submission with result details.
  • Profiles, submission history, accepted submissions, progress, reports, and contest rankings.

Learning mode can also guide workspace setup by creating a file named for the problem slug and using an extension associated with the selected language.

Limitations and notes

The project is under active development, and its documentation cautions that it may not work perfectly. Remote submission and user-data features depend on valid LeetCode credentials, while local execution depends on the relevant language runtime being installed. Solution-listing tools are gated by the practice session's hint level rather than being available immediately.

The provided setup examples document Claude Code and Claude Desktop specifically. Credentials are entered through the guided browser flow and may expire, so authentication status should be checked when requests fail or stored credentials become old.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Interactive Leetcode MCP

interactive-leetcode-mcp is an MCP server that connects AI clients to LeetCode for guided practice. Its main tools authenticate accounts, retrieve and search problems, manage hint-based sessions, run local sample tests, submit solutions, and inspect profiles, submissions, progress, and contest rankings.

Install it with npm or run it with npx. Use `npm install -g @sperekrestova/interactive-leetcode-mcp`, then launch `interactive-leetcode-mcp`; alternatively, run `npx -y @sperekrestova/interactive-leetcode-mcp@latest`. Node.js 20.x or newer is required.

Start the LeetCode authorization flow and follow the browser and DevTools instructions to provide the `csrftoken` and `LEETCODE_SESSION` cookie values. The server validates the credentials with a test API call, saves them, and can later report the username and credential age.

Yes, interactive-leetcode-mcp includes a Claude Desktop stdio configuration. Add an `mcpServers` entry that launches `npx` with the package, or point the configuration to the Node.js file produced by a local source build.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewInteractive Leetcode MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/interactive-leetcode-mcp?style=directory)](https://allmcps.com/mcp/interactive-leetcode-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/interactive-leetcode-mcp"><img src="https://allmcps.com/api/badge/interactive-leetcode-mcp?style=directory" alt="Interactive Leetcode MCP on AllMCPs" /></a>