LazyTools

🔒 Every tool runs in your browser — the files and values you enter are never uploaded to any server. How it works

🔍 Find and Replace

Search-and-replace like your editor’s Ctrl+H — with regex when you need it, and a count of what changed.

enter something to find

Rate this tool:
Anonymous — no account, no identifier

How the find and replace works

Plain mode replaces every occurrence of the exact text (case-insensitive unless "Match case" is on) and reports how many replacements were made. Regex mode treats the find field as a JavaScript regular expression — capture groups work in the replacement as $1, $2 — and invalid patterns report the error instead of silently failing.

The replacement count is the quiet safety feature: 0 replacements usually means a typo in the search text; a surprisingly large number warns you before you paste the result somewhere important. Leaving "replace with" empty deletes every match — the quickest bulk-remove there is.

Frequently asked questions

How do I delete every occurrence of something?

Put it in Find and leave Replace empty — every match is removed, and the count tells you how many.

What can I do with the regex option?

Pattern-based edits: \d+ matches any number, ^ and $ anchor line starts/ends, and capture groups reorder text — find "(\w+), (\w+)" replace "$2 $1" swaps "Doe, Jane" to "Jane Doe".

Why does my regex say invalid?

Characters like ( ) [ ] + ? have special meaning in regex — escape them with a backslash (\() or switch off regex mode for literal text.

Can I replace line breaks?

Yes — in regex mode find \n (or \n{2,} for blank lines). For simple joining, the remove-line-breaks tool is one click.

Is my text kept private?

Yes — everything runs locally; the tool works with your connection off.

Related text tools

From the blog