Get the FREE Ultimate OpenClaw Setup Guide →

mcp-svelte-docs

🔍 MCP server that lets you search and access Svelte documentation with built-in caching

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio spences10-mcp-svelte-docs npx -y mcp-svelte-docs

How to use

This MCP server exposes a single, powerful tool called svelte_definition. It provides authoritative, TypeScript-first definitions for Svelte 5 and SvelteKit concepts. You can query a wide range of runes (like $state, $derived, $props, and the full $effect family), development patterns (snippets, await-expressions, remote-functions), event handling, migration guidance, and TS interfaces (snippet, snapshot). Use the tool by passing an identifier and an optional format to the svelte_definition call. Formats include syntax (TypeScript signature only), quick (definition plus a concise example), and full (comprehensive documentation with examples). For example, svelte_definition("$state") returns complete $state documentation, while svelte_definition("onclick","syntax") returns just the TypeScript signature for the onclick concept. The service is designed to be a single interface that covers 28+ definitions, ensuring consistent responses whether you request a rune or a feature. The server also includes smart error recovery, fuzzy matching for typos, and migration help to bridge Svelte 4 patterns to Svelte 5 equivalents.

How to install

Prerequisites:\n- Node.js and npm (or a Node-enabled environment).\n- Internet access to fetch the MCP server package.\n\nInstall steps:\n1) Ensure Node.js is installed. Verify with: node -v and npm -v.\n2) You can run the MCP server directly with npx (no global install required):\n\nbash\nnpx -y mcp-svelte-docs\n\n3) Alternatively, if you prefer a local install, you can install the package locally in your project and run it from node_modules/.bin:\n\nbash\nnpm install --save-dev mcp-svelte-docs\n./node_modules/.bin/mcp-svelte-docs\n\n4) On Windows, macOS, or Linux, the same commands apply; in Windows you can also use a script or PowerShell to invoke npx.\n5) To customize the run, pass your preferred arguments, for example:\nbash\nnpx -y mcp-svelte-docs\n\n6) If you are using a GUI-based launcher or integration, configure it to use the command and arguments shown above.\n\nNotes:\n- The repository provides a ready-made configuration snippet that demonstrates using npx to run the server.\n- No global install is strictly required, thanks to npx.\n

Additional notes

Tips and considerations:\n- The server provides a single tool, svelte_definition, to access 28+ Svelte 5 definitions. Use the format parameter to tailor the output to your needs (syntax, quick, full).\n- If you’re integrating with editors or IDEs, you can call svelte_definition through your MCP client and display the returned documentation in-context.\n- The available identifiers cover core runes, development tools, features, patterns, event handling, and TS interfaces, enabling comprehensive coverage of Svelte 5 concepts.\n- See the Config examples in the README for different environments (Claude Desktop via WSL, Windsurf, Windows with and without WSL, macOS/Linux).\n- If you encounter typos or missing identifiers, the smart error recovery and related concept linking can help you find the correct term quickly.

Related MCP Servers

Sponsor this space

Reach thousands of developers ↗