# Text Find Replace — REST API endpoint `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.

- Category: text
- MCP server: https://mcp.findutils.com/ (Streamable HTTP, no API keys, 120 req/min per IP)
- REST endpoint: POST https://api.findutils.com/api/tools/text-find-replace/execute (no API keys, 60 req/min per IP)
- Reference page: https://findutils.com/api/text-find-replace/
- Same tool on the other surface: https://findutils.com/mcp/text-find-replace/

## Call the endpoint (verified example)

```bash
curl -X POST https://api.findutils.com/api/tools/text-find-replace/execute \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Hello world",
    "find": "world",
    "replace": "there"
  }'

# Parameter schema
curl https://api.findutils.com/api/tools/text-find-replace
```

## Input schema

| Argument | Type | Required | Description |
|---|---|---|---|
| `text` | string | yes | The input text. |
| `find` | string | yes | The text (or regex pattern when use_regex is true) to find. |
| `replace` | string | no | The replacement text. Default: empty string (delete matches). Default: `""`. |
| `case_sensitive` | boolean | no | Match case exactly. Default: false. Default: `false`. |
| `whole_word` | boolean | no | Match whole words only. Default: false. Default: `false`. |
| `use_regex` | boolean | no | Treat find as a regular expression. Default: false. Default: `false`. |
| `replace_all` | boolean | no | Replace every match (true) or only the first (false). Default: true. Default: `true`. |

Example arguments (verified):

```json
{
  "text": "Hello world",
  "find": "world",
  "replace": "there"
}
```

OpenAPI 3.1 spec: https://findutils.com/api/openapi.json · Interactive docs: https://findutils.com/api/docs/

## Also an MCP tool

```bash
claude mcp add findutils --transport http https://mcp.findutils.com/
```

Then ask the client to call `findutils:text_find_replace`. Full MCP reference: https://findutils.com/mcp/text-find-replace/

---
Full catalog: GET https://api.findutils.com/api/tools · https://findutils.com/api/ · https://findutils.com/llms.txt
