Find and replace lets you change every occurrence of a word or phrase in one go. Type what to find, type what to replace it with, check the highlighted matches, and click Replace all. It is the fastest way to fix a misspelt name, update a price throughout a document, or reformat data copied from somewhere else.
Word processors have this built in, but an online tool is handy when your text lives somewhere else: a WhatsApp export, a CSV file, code, an email draft or a website's content.
How to find and replace text online
- Open Find and Replace.
- Paste your text into the Text box on the left.
- Type the word or phrase in Find. Matches are highlighted on the right, and a badge shows how many there are.
- Type the new text in Replace with. Leave it empty if you want to delete the matches.
- Switch the preview from Matches to Result to see exactly how the text will look.
- Click Replace all. If something looks wrong, click Undo.
- Copy result or Download the final text.
The preview updates as you type, so you can refine the search before changing anything.
What do the three options do?
| Option | What it changes | Example |
|---|---|---|
| Match case | Only matches the exact capitals you typed | "GST" will not match "gst" |
| Whole words only | Ignores matches inside longer words | "rate" will not match "corporate" |
| Regular expression | Treats Find as a pattern, not plain text | \d{10} matches any 10-digit number |
By default the search ignores case and matches anywhere, which is what you want most of the time. Whole words is the option people forget, and it prevents embarrassing results like replacing "Ram" and accidentally changing "Ramesh" and "program".
Everyday examples
Correcting a name throughout a document. A contract mentions "Mr. Sharma" 40 times but should say "Mr. Verma". Find "Sharma", replace with "Verma", tick Whole words, and check the preview.
Updating a city or branch. Moving an office from Mumbai to Pune? Paste the brochure text and replace every "Mumbai" in seconds. Watch for addresses that should stay unchanged.
Removing a repeated phrase. Text copied from a PDF often includes "Page 3 of 12" lines. With regex on, find Page \d+ of \d+ and leave the replacement empty.
Cleaning phone numbers. Remove "+91 " from a contact list by finding "+91 " and replacing with nothing. Then use Remove Duplicate Lines to drop repeats.
Changing separators. Turn a comma-separated list into one item per line: with regex on, find ,\s* and replace with \n.
Using regular expressions: a gentle introduction
Regex is a mini-language for describing text patterns. You do not need to master it, but a few patterns go a long way.
| Pattern | Matches |
|---|---|
\d |
Any digit 0–9 |
\d{6} |
Exactly six digits, such as a PIN code |
\s+ |
One or more spaces, tabs or line breaks |
[A-Z]{5}\d{4}[A-Z] |
Text shaped like a PAN number |
^ and $ |
Start and end of a line |
(…) |
A group you can reuse in the replacement |
In the Replace with box, regex mode understands:
$1,$2and so on for the first, second captured group;$<name>for a named group;$&for the whole match;\nfor a new line and\tfor a tab.
Example: reformatting dates
Suppose your text has dates like 15/03/2025 and you need 2025-03-15 for a spreadsheet import.
- Find:
(\d{2})/(\d{2})/(\d{4}) - Replace with:
$3-$2-$1
Each group captures one part of the date, and the replacement puts them back in a new order. Check the Result preview before applying.
If you want to build and test more complex patterns step by step, the Regex Tester shows every match and group in detail.
Common mistakes to avoid
- Replacing inside other words. Searching "in" and replacing with "IN" changes "India", "invoice" and "begin". Use Whole words only.
- Forgetting special characters in regex. A full stop in regex means "any character", so
Rs.also matches "Rs5" or "Rsx". WriteRs\.to match the dot itself, or turn regex off. - Not checking the count. If you expected 5 matches and the badge says 37, stop and look before replacing.
- Replacing over and over. Running "Replace all" twice with a replacement that contains the search word, for example "Ltd" to "Ltd.", can double things up. Use the preview and Undo.
- Working on the only copy. For important files, keep the original text safe until you have checked the result.
Tips for larger documents
- Replacing in a Word or PDF file? Copy the text out, replace here, and paste it back. For PDFs, extract text first with PDF to Text.
- The match badge counts up to 10,000 matches, which covers almost any real document.
- To compare the original and replaced versions line by line, paste both into Text Compare.
- Use the Matches view with alternating highlight colours to spot neighbouring matches that run together.
Online tool or your word processor?
Microsoft Word (Ctrl + H), Google Docs and most code editors have their own find and replace. If your text is already in one of them and you only need a plain word swap, use it there.
An online tool earns its place in a few situations:
- On a phone. Mobile apps often hide replace options or lack them entirely. Here you paste, replace and copy in a few taps.
- Text without a home. A WhatsApp chat export, a list copied from a website or an email draft is quicker to fix here than in a new document.
- Regex without setup. Google Docs supports regular expressions, but Word uses its own wildcard system. This tool uses standard JavaScript regex, the same syntax you will find in most tutorials.
- Seeing everything first. The live highlight and match count let you check every hit before anything changes.
Is it safe for confidential text?
Yes. Find and Replace runs in your browser, and the text you paste is not uploaded to or stored by BISCS India. That makes it suitable for contracts, salary sheets and customer lists. The undo history exists only while the page is open, and closing the tab clears everything.