What it does
Find and replace is the most-used text operation that nobody talks about. You have a document, a list, or a block of code; one string needs to become another string, everywhere it appears. This tool performs that swap in your browser, updating the result as you type.
There are two modes. Literal mode treats the search as plain text, so a dot is a dot and a dollar sign is a dollar sign. Regular expression mode treats the search as a JavaScript pattern, which lets you match dates, email addresses, repeated whitespace, or anything else with a shared shape.
The original text stays in the left box until you clear it. The right box is a live preview, not a destructive edit, so a bad replacement costs nothing. The match counter tells you whether the pattern found what you expected before you copy anything.
How to use it
- Paste the text you want to change into Your text. The box accepts multiple lines, tabs, and Unicode.
- Type the search into Find. For a plain word or phrase, leave Regular expression off.
- Type the replacement into Replace with. Leave it empty to delete the match.
- Turn on the options that match your intent — most often Match case or Regular expression. The badge at the top shows how many matches exist.
- Check the right-hand result, then use Copy or Download. The file is saved as plain UTF-8 text.
If the counter says zero, the problem is almost always one of three things: the case does not match, whole-word mode is excluding part of a word, or a regex character such as a dot or bracket is being read as syntax.
Options, explained
- Match case
- Off by default, so
acmematchesAcmeandACME. The replacement itself is not case-adjusted: it is inserted exactly as typed. Turn this on when you only want the exact spelling changed. - Whole words
- Adds word boundaries around the search, so
catmatches the word in “the cat sat” but not the middle of “concatenate”. In regex mode the boundaries are wrapped around your whole pattern. The boundaries are ASCII-based — see the limits below. - Regular expression
- Reads the Find field as a JavaScript regex. Capture groups can be referenced in the replacement as
$1,$2, or$<name>for named groups. Use$&for the entire match and$$for a literal dollar sign. - First match only
- Replaces the first occurrence and leaves the rest alone. The counter still reports every match, so you can see how many were skipped.
- Multiline anchors
- Changes what
^and$mean in a regex: with this on they match the start and end of each line instead of the start and end of the whole text. It does not make the dot match line breaks. - Interpret \n and \t
- Converts the two-character sequences
\nand\tin the replacement into a real newline or tab. Handy for turning a comma-separated list into one item per line. It applies to both literal and regex replacements.
Examples
These are the patterns people reach for most often. Every example assumes the options named in the caption; a pattern that looks right with the wrong flag will silently match nothing.
Before
Acme analytics
Acme billing
Billing for AcmeAfter
Northwind analytics
Northwind billing
Billing for NorthwindFind Acme, replace with Northwind, and turn on Match case. With case matching off, a lowercase acme in an email address would be renamed too, which is rarely what you want.
Before
2026-10-27 · draft
2026-11-03 · review
2026-11-10 · publishAfter
27/10/2026 · draft
03/11/2026 · review
10/11/2026 · publishFind (\d{4})-(\d{2})-(\d{2}) and replace with $3/$2/$1. Each parenthesised group is captured in order; the replacement puts day first. Add \b around the pattern if the dates sit inside longer identifiers.
Before
Write to [email protected]
Escalate to [email protected]After
Write to [email]
Escalate to [email]Find [A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,} and replace with [email]. This is a practical redaction, not a validator: it will also catch addresses that are not deliverable, and it will miss unusual valid ones. Check the count against the number of addresses you expected.
When it earns its keep
- Rebranding copy. Replace a company, product, or plan name across a page without touching the surrounding prose.
- Preparing data for import. Turn semicolons into tabs, empty cells into
NULL, or decimal commas into decimal points before a spreadsheet import. - Cleaning logs. Strip timestamps, thread IDs, or ANSI color codes with a regex before pasting an excerpt into a bug report.
- Redacting a sample. Replace real names, email addresses, or account IDs with placeholders before sharing a document.
- Editing a generated list. Change a repeated prefix, remove a trailing comma, or turn one delimiter into another.
Limits worth knowing
- It is JavaScript regex, not PCRE. Lookbehind works in current browsers, but constructs such as
\A, possessive quantifiers, and recursive patterns do not. Test the pattern on a small sample first. - Catastrophic backtracking is real. A broad pattern with nested quantifiers can freeze a tab on the wrong input. If the page stops responding, close the tab; nothing was saved.
- Word boundaries are ASCII.
\btreats accented letters as non-word characters, so whole-word mode can behave surprisingly with “café” or with non-Latin scripts. Use a regex with explicit boundaries instead. - No case preservation. The replacement is inserted as typed. If you need to keep “Title case” vs “lowercase” variants, run separate, case-sensitive replacements.
- Line endings are left alone. Windows CRLF text keeps its CRLF line endings. If you need to normalize them first, run the text through Clean Text before replacing.
- It is a text tool, not a file editor. Binary files, very large logs, and rich-text formatting are outside its scope. The practical ceiling is your browser’s memory.
Page updated