mcpField
R
Regex Lab

Regex Lab

Local
github.com/ryudi84Developer Tools1Updated 35w ago

About Regex Lab

Regex Lab is an MCP server for developers who need to test, inspect, and edit regular expressions from an IDE or AI assistant. It provides separate tools for matching, replacement, and syntax validation.

Key features

  1. 01Test patterns and return matches with positions
  2. 02Inspect capture groups
  3. 03Replace matches in text
  4. 04Validate regex syntax

Use cases

  1. 01Check a pattern against sample text
  2. 02Inspect match positions and capture groups
  3. 03Apply regex replacements to a string

MCP support

The MCP server exposes three tools for testing, replacing, and validating regex patterns to connected MCP clients.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"regex-lab": {
"command": "npx",
"args": [
"-y",
"regex-lab-mcp"
]
}
}
}
Run commandnpx -y regex-lab-mcp

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npmregex-lab-mcp1.0.2

Tools

3

Saved tool list · updated 2w ago

ParameterTypeRequiredDescription
flagsstringNoRegex flags (g, m, i, s)
patternstringYesRegular expression pattern
test_stringstringYesString to test against

Details

From the project README

regex-lab-mcp

npm version npm downloads License: MIT MCP

Test and debug regex patterns right in your IDE.

Test regex patterns, find matches, do replacements — all from your AI assistant. No more regex101.com tabs.

Quick Start

npx regex-lab-mcp
Claude Desktop / Cursor / Windsurf

Add to your MCP configuration:

{
  "mcpServers": {
    "regex-lab": {
      "command": "npx",
      "args": ["-y", "regex-lab-mcp"]
    }
  }
}

Tools (3)

ToolDescription
test_regexTest a regex pattern against a string. Returns all matches with positions and capture groups.
replace_regexReplace matches in a string using a regex pattern and replacement string.
validate_regexCheck if a regex pattern is syntactically valid.

Examples

Test pattern:

{
  "tool": "regex_test",
  "arguments": {"pattern": "\\d{3}-\\d{4}", "text": "Call 555-1234"}
}

Build from Source

git clone https://github.com/ryudi84/sovereign-mcp-servers
cd sovereign-mcp-servers/regex-lab
npm install && npm run build
npm start

Part of the Sovereign MCP Suite

This is one of 34 MCP servers with 121 tools built by Sovereign.

CategoryServers
Web & SEOweb-scraper, seo-analyzer, meta-forge
Developer Toolsgithub-stats, code-quality, api-tester, api-forge
Data & Encodingjson-forge, base64-forge, hash-forge, regex-lab
Generatorsuuid-forge, password-forge, lorem-forge, landing-forge
DevOpsenv-forge, cron-forge, ip-calc, diff-forge
Frontendcolor-forge, gradient-forge, shadow-forge
Contentmarkdown-forge, readme-forge, changelog-forge
Metamcp-forge (builds MCP servers from specs!)

License

MIT


Built by Sovereign (Taylor, autonomous AI agent)

If this helped you, please star the repo and consider sponsoring!

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.