Replace All Occurrences
Change every instance of a word or phrase in one step instead of editing each one by hand. The live result and replacement counter show exactly what changed.
Replace words, phrases or line breaks in your text instantly. Supports match case, whole word and regex. Fast, free and no signup.
Paste it, type it or upload a text file.
Type the word to find and what should replace it.
Copy the new text or download it as a .txt file.
Looking for a free online find and replace tool? Paste your text, enter the word or phrase you want to find and type its replacement. Every match is replaced instantly and you can see how many replacements were made. You can match case, replace whole words only, use regular expressions or even replace line breaks and tabs. There is nothing to install and no account to create, and your text stays in your browser the whole time. It is a quick way to fix repeated typos, update names in a long document, clean up copied text or reformat lists and data.
Change every instance of a word or phrase in one step instead of editing each one by hand. The live result and replacement counter show exactly what changed.
Choose whether capital letters matter and whether to replace complete words only. This prevents accidental changes to words that merely contain your search term.
Use regular expressions with capture groups to reformat dates, remove extra spaces, delete blank lines and clean up structured text in seconds.
Replacing text with this tool takes just a few steps. There is no replace button to press, because the result updates as you type.
These ready-to-use examples show how to solve everyday text cleanup tasks. Enter the values in the Find and Replace with fields and switch on the option listed in the table.
| Task | Find | Replace with | Option | Before | After |
|---|---|---|---|---|---|
| Remove extra spaces | {2,} |
(one space) |
Use regex | Hello world ! | Hello world ! |
| Remove empty lines | ^\s*\n |
(leave empty) |
Use regex | Line 1, blank line, Line 2 | Line 1, Line 2 |
| Turn a list into one line | \n |
, |
Treat \n and \t | apple, banana, cherry (one per line) | apple, banana, cherry |
| Swap day and month in dates | (\d{2})/(\d{2})/(\d{4}) |
$2/$1/$3 |
Use regex | 25/12/2026 | 12/25/2026 |
| Remove spaces at the end of lines | +$ |
(leave empty) |
Use regex | Hello world | Hello world |
| Replace a whole word only | cat |
dog |
Whole word | cat category cat | dog category dog |
Match case controls capital letters. When it is off, searching for "apple" also finds "Apple" and "APPLE". When it is on, only the exact capitalization is replaced.
Whole word controls word boundaries. Replacing "art" with "craft" without this option would also change "party" or "start". With Whole word enabled, only the standalone word "art" is replaced. You can combine both options for the most precise results.
Regular expressions (regex) let you search for patterns instead of fixed words. With Use regex turned on, you can match any number, any run of spaces, the end of a line and much more. Parentheses create capture groups, and you can reuse what they captured in the replacement with $1, $2 and so on. This makes it possible to reorder parts of a text, for example turning "Surname, First name" into "First name Surname" in a long list.
If your expression has a mistake, the tool shows a clear error message and leaves your text unchanged, so you can fix the pattern and try again.
Text copied from PDFs, emails or web pages often contains unwanted line breaks and extra spaces. Turn on the option to treat \n and \t as a line break and a tab, then use \n in the Find field to find line breaks. Replace them with a space to join broken lines into a paragraph, or with a comma to turn a list into a single line. You can also do the opposite and replace commas with \n to place each item on its own line.
Most text editors have their own find and replace feature, usually opened with Ctrl+H on Windows. However, these built-in options differ between programs and many do not support regex. An online find and replace tool works the same way everywhere, on a laptop or a phone, and lets you clean up text before you paste it back into your document, spreadsheet or code editor.
This free text replacer works completely in your browser, so the text you enter is never uploaded to our server. That makes it a safe option for private notes, drafts, code snippets, customer lists and other content you do not want to share. Use it as often as you like without signup or a watermark.
Find answers to common questions about replacing text online, using regex, matching case and replacing line breaks.
A find and replace tool searches your text for a word, phrase or pattern and replaces every match with new text in one step. Instead of editing a long document by hand, you type what to find, type what to put in its place and the result updates instantly.
Paste or type your text in the input box, enter the word you want to find in the Find field and the new word in the Replace with field. The tool replaces every occurrence at once and shows the number of replacements. Then copy the result or download it as a text file.
Turn on the Match case option. With it enabled, "Apple" and "apple" are treated as different words and only the exact capitalization you typed is replaced. With it off, the search ignores uppercase and lowercase differences.
Whole word only replaces complete words. For example, replacing "cat" with "dog" will change "cat" but will leave "category" and "concatenate" untouched. It works with letters and numbers from many languages, not just English.
Turn on Use regex and type a regular expression in the Find field, for example (\d+)-(\d+). In the Replace with field you can refer to captured groups using $1, $2 and so on. This is useful for reformatting dates, rearranging names, removing extra spaces or cleaning up structured text. If your expression is invalid, the tool shows an error message instead of changing your text.
Turn on the option that treats \n and \t as a line break and a tab. Then enter \n in the Find field to find line breaks and enter something like a comma and a space in the Replace with field. This converts a list that has one item per line into a single comma-separated line. You can do the reverse by finding a comma and replacing it with \n.
Enter the word or phrase in the Find field and leave the Replace with field empty. Every match is removed from your text. Combine it with Whole word to avoid deleting parts of longer words.
No. This find and replace tool runs entirely in your browser. Your text is processed on your own device and is not sent to our server or stored anywhere, so it is suitable for private notes, code snippets and other sensitive content.
Yes. The tool works with Unicode text, so you can find and replace words in Urdu, Hindi, Arabic, Chinese and other languages as well as English, including text with accents and emoji.
In most Windows programs, including Word, Notepad, Excel and Google Docs in a browser, press Ctrl+H to open the Find and Replace dialog. On Mac the shortcut is different depending on the program. An online find and replace tool is handy when you do not want to open a separate program, when you need regex support or when you work on a phone.
Yes. After the first replacement, click Use result as input. The replaced text moves into the input box and you can enter a new Find and Replace with pair. Repeat this as many times as you need to apply a series of changes.
There is no fixed limit in the tool, but very large texts depend on your browser and device memory and may be slower to process, especially with complex regular expressions. For everyday documents, articles, lists and code files the result appears instantly.
Merge, split, compress and convert files in seconds. Explore powerful free tools for all your everyday needs.
Explore All Tools →