Find & Replace
Find and replace text with optional case-insensitive and regex modes, all in your browser.
Runs in your browser — files never leave your device
How it works
Paste your text, type a search term and a replacement, and the Result pane rewrites itself on every keystroke. Replacement is always global — every occurrence in the text is replaced, not just the first. By default the search term is treated literally: regex metacharacters such as ., *, + and ? are escaped automatically, so a search for a dot touches only actual dots.
Two checkboxes change the matching rules. Ignore case adds the i flag to the underlying JavaScript regular expression, so matching ignores letter case while the replacement is inserted exactly as typed. Regex treats the Find field as a raw JavaScript pattern — character classes, quantifiers, alternation and capture groups all work — and the replacement gains $1 through $9 for groups, $& for the whole match and $$ for a literal dollar sign. If the pattern is invalid, a red error message appears and the output stays identical to the input until you fix it.
A concrete example of what capture groups buy you: finding (\d{2})/(\d{2})/(\d{4}) and replacing with $3-$2-$1 turns Released 25/12/2026 and 01/03/2027 into Released 2026-12-25 and 2027-03-01 — both dates rewritten to ISO order in one pass.
That makes the tool useful well beyond fixing a repeated typo: bulk-editing CSV or log exports (swapping delimiters, stripping quotes), renaming an identifier throughout a pasted code file, collapsing messy whitespace by replacing the pattern \s+ with a single space, reformatting dates and phone numbers with capture groups, and cleaning up text scraped from PDFs or web pages.
Three gotchas. Literal mode matches substrings, so replacing color with colour also turns colorful into colourful — switch to Regex and search \bcolor\b to match whole words only. Anchors apply to the whole text, not to each line: ^ matches only the very start of the input because the multiline flag is not set. And the replacement field is never escaped, so dollar sequences stay active even in literal mode — write $$ when you need a plain dollar sign.
Frequently asked questions
- Does it replace all occurrences or only the first?
- Always all of them — the replacement runs with the global flag and there is no replace-one mode. If you need to spare some occurrences, make the search more specific, for example by including surrounding words or by switching to a regex with boundaries or anchors.
- How do I replace whole words only?
- Turn on Regex and wrap the word in \b boundaries. Searching \bcolor\b and replacing with colour in "The color of the colorful colors" produces "The colour of the colorful colors" — the standalone word changes while colorful and colors are left alone, because \b requires a word edge on both sides.
- Which regex syntax does it use?
- Your browser’s native JavaScript RegExp engine. The global flag is always on and Ignore case adds the i flag; no other flags are set — notably multiline, so ^ and $ anchor to the start and end of the whole text rather than each line. Replacing ^\w+ with X in "aaa\nbbb" therefore yields "X\nbbb", touching only the first line.
- What happens if my regex is invalid?
- The error message from the regex engine is shown in red — for example "Unterminated group" when a parenthesis is unclosed — and the Result pane keeps showing your text unchanged. Nothing is replaced until the pattern compiles.
- Can the replacement reference what was matched?
- Yes. $1 through $9 insert capture groups, $& inserts the whole match, and $$ produces a literal dollar sign. These sequences are part of JavaScript’s replacement syntax and stay active even when the Regex box is off — replacing price with $$5 in "cost: price" gives "cost: $5".
- How does Ignore case behave?
- It relaxes matching only, never the replacement. Finding cat with Ignore case on and replacing with dog turns "Cat cat CAT" into "dog dog dog" — all three variants match, and each is replaced by the replacement exactly as you typed it, so original capitalization is not preserved.
- Is my text uploaded?
- No — matching and replacement run in your browser as you type. Your text, patterns and results never leave your device.
Related tools
- Word & Character CounterCount words, characters, sentences, paragraphs and lines instantly. Runs entirely in your browser — your text never leaves your device.
- Case ConverterConvert text between UPPERCASE, lowercase, Title Case, camelCase, snake_case, kebab-case and more — instantly in your browser.
- Slug GeneratorTurn any title into a clean, URL-friendly slug. Removes accents and punctuation; runs in your browser.
- Text ReverserReverse any string character by character. Handles Unicode correctly; runs locally.
- Remove Duplicate LinesStrip duplicate lines from a list, keeping the first occurrence. Optional case-insensitive and trim modes.
- Sort LinesSort lines alphabetically, ascending or descending, with optional case-insensitive comparison.