Find and Replace
Replace every occurrence of a word or pattern in your text — with literal or regular-expression matching, case-insensitive and whole-word options.
How to use it
Paste your text into the box, type what to find and what to replace it with, and every match is swapped out on the spot with a running count of how many were changed. There is no button to press — the result updates as you type, and you copy it when it looks right. Everything runs in your browser, so nothing is uploaded. By default the tool works in literal mode: the find field is matched as exact text, so typing a period matches a period and nothing more. Turn on Case-insensitive to treat uppercase and lowercase as the same, so searching for cat also matches Cat and CAT. Turn on Whole word only to require word boundaries around the match, which stops cat from matching inside category or scatter — handy when renaming a variable or a name that appears as part of longer words. Switch on Regular expression to treat the find field as a pattern instead of literal text. That unlocks character classes and quantifiers such as \d+ for one or more digits or colou?r to match both spellings, and it lets the replacement reuse captured groups: $1 inserts the first parenthesised group and $& inserts the whole match. If a pattern is malformed the tool shows an error and leaves your text untouched rather than guessing. As a worked example, in literal mode set find to teh and replace to the to fix a common typo everywhere at once, and the counter tells you how many were corrected. In regex mode set find to (\w+)@old\.com and replace to $1@new\.com to rewrite every address to the new domain while keeping each username, because $1 carries the captured name through to the result. Find and replace is a fast way to rename an identifier across a snippet, standardise spelling, reformat exported data, or strip a repeated phrase. Because the work happens entirely on your device it is also safe for text you would rather not paste into an online service. To tidy the result afterwards, run it through the Whitespace Cleaner or Remove Duplicate Lines tools.
Frequently asked questions
- Does it support regular expressions?
- Yes. Enable 'Regular expression' to use patterns like \d+ and backreferences such as $1 in the replacement. Invalid patterns show an error instead of changing your text.
- Does it replace all matches?
- Yes, every occurrence is replaced. 'Whole word only' (literal mode) prevents matching inside longer words, e.g. 'cat' won't match 'category'.
- Is my text sent to a server?
- No. Find and replace runs entirely in your browser; your text is never uploaded.
- Can I reuse matched text in the replacement?
- Yes, in regular-expression mode. Wrap part of your pattern in parentheses to capture it, then reference it in the replacement with $1 for the first group (or $& for the whole match). In literal mode the replacement is inserted as-is.