Replace text online
Replace any word, phrase, or pattern in your text. Paste your content into the input, type what you want to find, and what to replace it with. The output updates instantly and shows a match count. Supports plain text and regular expression modes. All processing runs locally in your browser.
Input text
Result
FIND & REPLACE
How it works
In plain mode, the search text is escaped and matched literally using a JavaScript RegExp with the global flag. In regex mode, the pattern is used as-is. The case-insensitive flag is added unless Case sensitive is enabled. The whole-word option wraps the pattern in word boundaries (\b). String.replace() with the RegExp applies the substitution across the entire input on every keystroke. All processing runs in JavaScript in your browser.
Processing runs in your browser
All processing happens locally in your browser tab. Our servers are not involved at any point.
Related operations
For more advanced pattern matching, try the regex tester. To alphabetise or dedupe the result, use sort lines. For comparing two versions of the text side by side, see text diff.
Frequently asked questions
- Can I replace across multiple lines?
- Yes. The input area accepts multi-line text and the find/replace operates across all lines. In regex mode, use the dot-all flag syntax or \n to explicitly match line breaks.
- Can I use this to clean up pasted text?
- Yes. Common uses include removing extra spaces (find ' ', replace ' '), stripping unwanted characters, normalising line endings, or replacing placeholder text. The match count tells you how many replacements were made.
- What happens if my regex has an error?
- If your regex pattern is invalid, the tool shows an error badge next to the find field and no replacements are made. Fix the pattern and the output updates immediately.
- Is my data sent to a server?
- All text processing runs locally in your browser. No data is sent to our servers.