When you need find-and-replace and you don't have an editor open
Find-and-replace is the most-used feature in every text editor. The reason it's also one of the most-Googled "online tool" queries is mundane: people don't always have an editor open. They have a browser open, a chunk of text in their clipboard, and one search-and-replace operation to run before they can move on.
This tool lives in that gap. Paste text, type the find pattern, type the replacement, copy the result.
Literal vs regex mode
Default mode is literal: whatever you type in the Find field is what gets matched, character for character. "cat" matches "cat", including inside "category" or "concat" if "Whole word" isn't on.
Toggle "Regex" and the Find field becomes a JavaScript regex source. Same engine VS Code, IntelliJ, and your browser's DevTools use. So \\b\\w+@\\w+\\.\\w+\\b matches an email-shaped token, \\d{4}-\\d{2}-\\d{2} matches an ISO date, and \\s+$ (with the multiline flag on) strips trailing whitespace from every line.
The four toggles, in plain language
Aa Case: when on, "Apple" only matches "Apple" and not "apple" or "APPLE". Off by default because most search-and-replace work is case-insensitive.
\b Whole word: wraps the pattern in word boundaries. Stops "cat" from matching inside "category". Equivalent to checking the "Match whole word" box in any editor.
. Regex*: flips Find from literal to JavaScript regex. The replacement field also changes meaning: $1, $2, $3 reference capture groups; $& references the whole match; $$ is a literal dollar sign.
¶ Multiline: toggles the regex m flag, which makes ^ and $ match the start and end of each line instead of the start and end of the whole string. Useful for line-by-line patterns like "anchor on every line that starts with #".
A few patterns worth bookmarking
- Strip leading/trailing whitespace per line: Find:
^\\s+|\\s+$· Replace: empty · Toggles: regex + multiline - Collapse multiple spaces to one: Find:
\\s+· Replace:(single space) · Toggle: regex - Remove blank lines: Find:
^\\s*\\n· Replace: empty · Toggles: regex + multiline - Wrap each line in quotes: Find:
^(.+)$· Replace:"$1"· Toggles: regex + multiline - Convert CamelCase to kebab-case: Find:
([a-z])([A-Z])· Replace:$1-$2· Toggle: regex (then lowercase the whole thing in the Case Converter) - Extract dollar amounts: Find:
\\$\\d+(\\.\\d{2})?· Toggle: regex (find only, no replacement)
Why running it in your browser is fine
Every operation runs locally in JavaScript. The text never leaves the page. There's no server call, no log, no analytics tied to the content. You can paste a confidential email or a redacted internal document and the tool works the same.
This matters because find-and-replace is what people use to anonymize text. Replace every customer name with [REDACTED], replace every SSN-shaped string with XXX-XX-XXXX, replace every email with [email removed]. Doing that in a tool that uploads your text would defeat the entire purpose. We don't.
When VS Code is still the right answer
For very large files (>1 MB), for projects that need to find-and-replace across many files at once, or for find-and-replace that interacts with code structure (rename a variable everywhere except in comments), an editor remains the right tool. This page is for the in-between cases: small chunks of text, one operation, no setup.