Find and Replace Text

A find-and-replace that runs entirely in the browser, with case matching and whole-word matching so a swap does not spill into longer words.

The substring trap

The classic find-and-replace mistake is replacing a short word and discovering it inside longer ones. Swap cat for dog and catalogue becomes dogalogue; swap is for was and this becomes thwas. Whole-word mode fixes this by requiring a word boundary on each side of the match, so only the standalone word is replaced. Turn it off when you genuinely want partial matches, changing a filename prefix across a list, or fixing a misspelling that appears inside compounds. Case matching is separate: leave it off to catch a term at the start of a sentence as well as mid-sentence, turn it on when The and the mean different things.

Why the search is literal

Everything you type in the find box is treated as literal text, not as a pattern. Characters that would mean something in a regular expression (a dot, a question mark, brackets, a backslash) are escaped before the search runs. This is a deliberate constraint. It means searching for a dot finds actual dots rather than matching every character, and it means no input you paste can construct a pattern that hangs the page. The trade-off is that you cannot do pattern work here, so a task like matching any four-digit number needs a different tool.

Frequently asked questions

Why did replacing "in" change words like "thing"?

Whole-word mode was off, so the match ran on substrings. Turn it on and only the standalone word is replaced.

Can I use a regular expression in the find box?

No, by design. The search is literal and regex characters are escaped, so a dot matches a dot. This keeps a pasted pattern from hanging the page.

Can I delete a phrase instead of replacing it?

Yes. Type the phrase in the find box and leave the replace box empty. Every match is removed.