Skip to content

Text Find Replace MCP tool

MCP findutils:text_find_replace

Find and replace text and return the new text with the match and replacement counts. Supports case-insensitive search, whole-word matching, JavaScript regular expressions (with $1 capture groups in the replacement), and replace-first or replace-all.

Arguments

application/json
  • text

    string required

    The input text.

  • find

    string required

    The text (or regex pattern when use_regex is true) to find.

  • replace

    string optional

    The replacement text. Default: empty string (delete matches). Default "".

  • case_sensitive

    boolean optional

    Match case exactly. Default: false. Default false.

  • whole_word

    boolean optional

    Match whole words only. Default: false. Default false.

  • use_regex

    boolean optional

    Treat find as a regular expression. Default: false. Default false.

  • replace_all

    boolean optional

    Replace every match (true) or only the first (false). Default: true. Default true.

Example arguments

Verified
{
  "text": "Hello world",
  "find": "world",
  "replace": "there"
}