Labsco
MCP SERVER

nREPL MCP Server

by JohanCodinha

Attach to a running nREPL by host and port, evaluate Clojure inside it — including reloads — and read a namespace's public vars back with their doc strings, file and line, and current values.

Runtime Debugging & Crash AnalysisVerified
Summary
It talks to the process you already have running, so application state survives the conversation.

This is a live connection, not a sandbox: eval_form runs inside the process holding your application's state, which is what separates it from asking a model to reason about the source. get_ns_vars is the read side and it is unusually complete — doc string, file, line and the value a var holds right now, which is the question normally answered by adding a println and restarting. The surface is three tools, so the boundaries are clear: nothing here edits files or manages a project.

What it is

A three-tool bridge to an already-running nREPL server: connect, evaluate, inspect a namespace.

What you get
  • connect, taking host and port, to attach to an nREPL that is already up
  • eval_form, evaluating Clojure in a named namespace or the current one — its examples cover defining and calling a function, reloading code, and syncing dependencies
  • get_ns_vars, returning a namespace's public vars as a map where each entry carries metadata (doc string, line number, file path) and the var's current value
Requirements

A running nREPL server, and its host and port.

Setup effort

One command — npx nrepl-mcp-server