Free Find and Replace Online

Replace every match of a word, phrase or regex in your text, free. Case-insensitive, whole-word and regex options with $1 groups. Runs in your browser.

No login. Files processed for your request and discarded. Free to use. Files processed & discarded →

Compress PDF — it's free or choose from 130+ tools

130+ Free Tools
— Files Processed
— Happy Visitors
— Pages Explored
0 Files Stored

Find and Replace Text Online

Part of Text tools: See all Text tools.

What is Find and Replace?

Find and Replace changes every match of a word, phrase or regular expression in text you paste, and puts the result in a separate Output box so your original stays untouched. Matching ignores upper and lower case by default; untick Case insensitive for exact-case matches. Whole words only skips matches inside longer words, so cat no longer hits category. Tick Use regex for JavaScript regular expressions, with $1-style groups, \n for line breaks and \t for tabs. A status line tells you how many matches were replaced. Everything runs in your browser.

How to use Find and Replace

  1. Paste your text into the Input text box.
  2. Type what to look for in Find and what to put in its place in Replace with. Leave Replace with empty to delete every match.
  3. Pick the options you need: Case insensitive (on by default), Whole words only, or Use regex for patterns, line breaks and tabs.
  4. Click Replace all. Check the match count under the button, then use Copy result, or Use result as input to run another replacement on the output.

Why use this tool?

Changing the same thing many times by hand is slow and easy to get wrong: an old product name across a page of copy, a wrong spelling in a long email, a date format in an exported list, or a column of names that has to become one comma-separated line. One replace-all does it in a single pass and tells you how many places changed, so a count of 0 or a count far higher than expected warns you before you paste the result anywhere.

Find and Replace — In-Depth Guide

The tool does one thing: it finds every occurrence of what you type and replaces all of them at once. Your input stays in the top box and the result appears in the Output box, with a line under the button saying how many matches were replaced. If you need several different replacements in a row, click Use result as input after each one and set the next pair.

Plain mode is the safe default for words and phrases. Characters such as dots, brackets, question marks and dollar signs are matched literally, so replacing 5 with $5 gives $5, and searching for a.b finds only a.b. Case insensitive is ticked by default, which means Paris, paris and PARIS all match; untick it when the case matters, for example when you only want to change the lowercase word apple and not the brand Apple.

Regex mode is for patterns and structure. A few patterns cover most everyday jobs: \n to join lines with a separator, ,\s* to split a list onto lines, ^ to add a prefix to every line (replace with - to make a bullet list), $ to add something to the end of every line, and a space followed by {2,} to collapse runs of spaces into one. Capture groups let you reorder parts of a match, such as swapping a day-month-year date into year-month-day. For building and testing a complicated pattern first, the Regex Tester shows each match and group.

Check the count before you copy. A replace-all cannot tell which matches you meant, so a word like dress also sits inside address and replacing it blindly gives adskirt. Whole words only prevents that, and a match count far higher than you expected is a sign the search term is too short or too general. For a line-by-line view of every change, compare the input and output in the Text Diff tool.

Frequently asked questions

Does it support regular expressions?
Yes. Tick Use regex and the Find box takes a JavaScript regular expression. ^ and $ match at the start and end of every line, not just the whole text. If the pattern is not valid, for example an unclosed bracket, the tool shows the error and leaves your text unchanged.
Can I use capture groups in the replacement?
Yes, in regex mode. $1, $2 and so on insert what each bracketed group matched, and $& inserts the whole match. For example, find (\d{2})/(\d{2})/(\d{4}) and replace with $3-$2-$1 to turn 19/10/2026 into 2026-10-19. Without Use regex, a $ in the replacement is kept as a plain dollar sign.
How do I join lines into one line?
Tick Use regex, type \n in Find and the separator you want in Replace with, such as a comma and a space. apple, banana and cherry on three lines become apple, banana, cherry. If the last line of your list is empty, delete it first or you will get a separator at the end.
How do I split a comma-separated list onto separate lines?
Tick Use regex, type ,\s* in Find (a comma plus any spaces after it) and \n in Replace with. For a pipe-separated list, find \| instead, because | has a special meaning in regex. This splits at every comma, so for CSV files with quoted commas use the CSV to JSON converter instead.
What does Whole words only do?
It replaces a match only when it is not part of a longer word. With it on, cat matches cat and Cat but not category or concatenate, and dress no longer changes the middle of address. Letters, digits and the underscore count as word characters, including accented letters in current browsers.
Is there a preview of the matches?
There is no highlighted preview. The result goes to a separate Output box and the status line shows how many matches were replaced, so your input is never overwritten. To see exactly what changed, paste the input and output into the Text Diff tool.
Is my text uploaded?
No. The search and replace runs in your browser with JavaScript, and the text is not sent to the server.

Also try

Related tools that work well with this one: