Run LeetCode test cases locally, straight from VS Code — no account needed.
Paste a LeetCode problem URL, fetch the example test cases, write your solution, and run all cases with one click. Results appear inline in the sidebar with pass/fail and timing. Everything executes on your machine via child_process — nothing is sent to any server.
Features
Fetch by URL — paste any LeetCode problem URL and hit Fetch
Local execution — runs your code with your local Python / Node / g++
Three languages — Python 3, C++, JavaScript
Boilerplate insertion — inserts LeetCode-style starter code with a ready-to-run manual input block at the bottom
Inline results — per-case pass/fail badge, actual vs expected output, stderr, and timing
No login required — uses the public LeetCode GraphQL endpoint
Usage
Click the LeetCase icon in the activity bar to open the sidebar.
Paste a LeetCode problem URL (e.g. https://leetcode.com/problems/two-sum/) and click Fetch.
Select your language from the dropdown.
Click ⤓ Boilerplate to insert starter code into your active editor.
Write your solution inside the class Solution / function body.
Click ▶ Run All Test Cases — results appear instantly below each case.
Supported Languages
Language
Notes
Python 3
Full support — List, Optional, ListNode, TreeNode all handled automatically
C++
Auto-wrapped with <bits/stdc++.h> and a generated main(). Compiled with g++ -O2 -std=c++17
JavaScript
Top-level function style (var twoSum = function(...){...}) matching LeetCode's editor
Settings
Setting
Default
Description
leetcase.python3Path
python3
Path to the Python 3 executable
leetcase.nodePath
node
Path to the Node.js executable
leetcase.cppCompiler
g++
C++ compiler command
leetcase.cppStandard
c++17
C++ standard passed via -std=
leetcase.timeoutMs
8000
Per-testcase timeout in milliseconds
Notes
No account or login required — test cases are fetched from the public LeetCode GraphQL endpoint.
Everything runs locally — your code never leaves your machine.
Multiple valid answers — some problems accept any valid permutation (e.g. "return any valid answer"). For these, exact-match comparison may report a false failure — check the actual output to verify.
System-design / class-based problems (e.g. lru-cache, design-linked-list) use a different test format and are not currently supported.