Find and Replace
Free online find and replace tool. Replace text with options for match case, whole word and full regular expressions, and see how many replacements were made — instantly and privately in your browser, with no upload and no limits.
How to use the Find and Replace
- 1Paste or type your text into the main input box — a paragraph, a full document, a log dump, or a code snippet all work the same way.
- 2Enter the text you want to locate in the 'Find' field, then enter its replacement in the 'Replace' field (leave Replace empty to delete every match instead).
- 3Toggle the options you need: turn on Match case for exact capitalization, Whole word to avoid partial matches inside longer words, or Regex to write a full regular-expression pattern.
- 4Click Replace All to rewrite every occurrence at once, and read the replacement count shown so you can confirm the tool changed exactly what you expected.
- 5Review the updated text in place, adjust your pattern or options if the count looks wrong, then copy the result to your clipboard or download it as a file.
About the Find and Replace
Find and Replace is a browser-based text editor for swapping one string for another across an entire block of text — quickly, precisely, and without sending your content anywhere. You paste your text into the input area, type what you want to find, type what to replace it with, and the tool rewrites every match while showing you an exact count of how many replacements it made. Everything runs client-side in JavaScript, so your text never leaves your device: nothing is uploaded, logged, or stored on a server. That makes it safe for pasting log files, contracts, source code, exported spreadsheets, or draft manuscripts that you would not want traveling over the network.
The three option toggles are what separate this from a crude browser Ctrl+F. Match case forces an exact uppercase/lowercase comparison, so replacing "IT" won't touch "it" or "edit". Whole word wraps your search in word boundaries, meaning "cat" will not clobber "category" or "concatenate". And the regular expressions mode unlocks the full JavaScript regex engine — character classes, quantifiers, anchors, alternation, and capture groups. With regex on, you can replace with backreferences like $1 to reorder captured pieces, strip trailing whitespace with \s+$, or normalize phone-number formats in one pass.
Concrete use cases show up everywhere. Writers rename a character across a 90,000-word draft. Developers rename a variable throughout a file before pasting it back into an editor. Marketers clean up smart quotes, double spaces, or stray tabs pasted from Word or Google Docs. Data analysts convert comma-separated values to tab-separated, or delete a repeated header row. Translators swap terminology consistently. The live replacement counter is the practical safety net — if you expected 12 changes and the tool reports 400, you immediately know your pattern was too broad and can add whole-word or case matching before copying the result out. It matters because a single mistaken global replace can quietly corrupt an entire document, and here you see the damage count before you commit.
Frequently asked questions
How do I use capture groups and backreferences in the replacement?
Turn on the Regex option, wrap the part you want to reuse in parentheses in the Find field, and reference it in the Replace field with $1, $2, and so on. For example, finding (\w+)@(\w+) and replacing with $2.$1 swaps the two captured pieces around the match.
What's the difference between Whole word and just typing the word?
Without Whole word, searching 'form' also matches 'format', 'information', and 'perform'. With Whole word enabled, the tool only replaces 'form' when it stands alone, bounded by spaces, punctuation, or the start and end of the text, so surrounding words are left untouched.
Can I delete text instead of replacing it?
Yes. Type what you want removed in the Find field and leave the Replace field completely empty. Every match is deleted. This is handy for stripping out repeated headers, tracking codes, or unwanted characters, and the counter still tells you how many were removed.
Does it replace across multiple lines and handle line breaks?
Plain text replacements work across the whole input regardless of line count. For patterns that must span line breaks, enable Regex — the newline character is \n, and constructs like [\s\S] let a pattern match across lines since the standard dot does not match newlines by default.
Why does my regex replace nothing or throw an error?
Special characters like . * + ? ( ) [ ] { } | \ and $ have meaning in regex mode. If you want them treated literally, escape them with a backslash, for example \. to match a real period or \$ for a dollar sign. An unbalanced parenthesis or bracket produces an invalid pattern, which is why nothing gets replaced until the syntax is corrected.
Related tools
Browse all free online tools in Text tools and more.
Frequently asked questions
Does it support regular expressions?+
Yes. Enable 'Use regex' to match with full JavaScript regular expressions. Invalid patterns show a clear error instead of breaking.
Can I match whole words only?+
Yes. Turn on 'Whole word' to wrap your search in word boundaries so partial matches inside longer words are skipped.
Is my text uploaded anywhere?+
No. All matching and replacing happens locally in your browser — your text never leaves your device.