Quick Answer
Paste your text, type the word or phrase to find and what to replace it with. The tool highlights every match, shows how many it found and gives the replaced text below, ready to copy. Tick Match case to respect capitals, Whole words only to avoid changing parts of other words, or Regular expression for patterns like phone numbers — use $1, $2 to reuse matched groups.
What is a Find and Replace Tool?
A Find & Replace tool (फ़ाइंड एंड रिप्लेस) searches a text for a word, phrase or pattern and replaces every occurrence in one go. Word processors have this feature, but often you are working with text outside them — content copied from a website, a list exported from a spreadsheet, a block of code, an email template, a product feed or an SMS draft. Pasting it here lets you make bulk changes instantly, see exactly what will change, and copy the result back.
This free tool offers three levels of power. Plain mode replaces exactly what you type. Whole words only makes sure you change complete words and not parts of other words. Regular expressions let you match patterns — any phone number, any date, double spaces, the start of every line — and rearrange them with captured groups. Every match is highlighted before you commit, the original stays untouched until you apply the change, and a background time limit means even a badly written regex can never freeze your browser.
Key Features
- Replace all matches in one step, with a live count.
- Highlighted preview of every match (up to 2,000 highlighted).
- Match case for exact capitalisation.
- Whole words only with Unicode-aware boundaries for any language.
- Regular expressions with $1, $2 and $& in replacements.
- Multiline anchors so ^ and $ work on each line.
- Apply and undo with 20 steps of history.
- Safe regex execution in a Web Worker with a 2-second limit.
- Private — no text leaves your device.
How to Find and Replace — Step by Step
- Paste your text into the first box.
- Type what to find and what to replace it with. Leave Replace empty to delete the matches.
- Choose options: Match case, Whole words only, Regular expression, Multiline.
- Check the highlights and the match count.
- Copy or download the result — or press Apply to text to make it your new working text and continue with more replacements. Use Undo to step back.
Plain, Whole-Word and Case Options
In plain mode the tool escapes every special character for you, so searching for “$5.00 (approx)” finds exactly that text. Matching ignores capital letters unless you tick Match case. Whole words only requires the match to be surrounded by non-letter, non-digit characters, so replacing “art” will not damage “start” or “artist”. Because word boundaries are based on Unicode letter categories, this works for Hindi, accented European languages and other scripts — unlike the traditional \b boundary, which only understands English letters.
Regular Expressions Made Practical
A regular expression (regex) describes a pattern instead of fixed text. Tick Regular expression and the find box accepts JavaScript regex syntax. Useful building blocks:
| Pattern | Matches |
|---|---|
| \d | Any digit |
| \d{10} | Exactly 10 digits (e.g. a mobile number) |
| \s+ | One or more spaces, tabs or line breaks |
| [A-Za-z]+ | A run of English letters |
| ^ / $ | Start / end of the text (or of each line with Multiline) |
| (…) | A group you can reuse as $1, $2 in the replacement |
| a|b | Either a or b |
| .*? | Any characters, as few as possible |
Ready-to-Use Recipes
| Task | Find (regex on) | Replace with |
|---|---|---|
| Collapse double spaces | [ ]{2,} | (one space) |
| Remove blank lines | ^\s*\n (Multiline) | (empty) |
| Date 2026-10-17 → 17/10/2026 | (\d{4})-(\d{2})-(\d{2}) | $3/$2/$1 |
| Add “- ” before every line | ^ (Multiline) | - |
| List to comma-separated | \n | , |
| Remove +91 from numbers | \+91[\s-]? | (empty) |
| Wrap emails in <b> | [\w.+-]+@[\w-]+\.[\w.]+ | <b>$&</b> |
| Swap “Last, First” to “First Last” | (\w+),\s*(\w+) | $2 $1 |
Why Regex Can Freeze Pages — and How This Tool Prevents It
Some regular expressions can take an astronomically long time on certain inputs, a problem known as catastrophic backtracking. A classic example is (a+)+$ tested against a long run of “a” characters followed by another letter: the regex engine tries an exponential number of ways to split the text. On most websites that would lock up the browser tab. This tool runs your regex inside a separate Web Worker. If it has not finished within two seconds, the worker is terminated and you see a clear message instead of a frozen page. Your pattern is only ever compiled as a regular expression — it is never executed as program code.
Worked Example
The sample text on this page contains the word “example” four times — in two email addresses, in a domain name and in a company name. With the default settings (case-insensitive, plain mode), finding example and replacing it with promptminds reports 4 matches and produces “info@promptminds.com”, “sales@promptminds.com”, “promptminds.com” and “promptminds Pvt Ltd”. Tick Match case and only the three lower-case occurrences change, leaving “Example Pvt Ltd” untouched — a quick way to see how much the options matter.
Doing Several Replacements in a Row
Real clean-ups usually need more than one change. Make the first replacement, check the result and press Apply to text. The result becomes your working text, and you can type the next find and replace. Each Apply is saved in the history, so Undo takes you back one step at a time — up to 20 steps. When everything is right, copy or download the final text. This is often faster than writing one complicated regex that does everything at once, and much easier to check.
Replacing Hindi and Other Languages
Plain and whole-word replacement work with any script. You can replace “कृपया” with “प्लीज़”, fix a common spelling such as “हिन्दी” → “हिंदी”, or swap “₹” for “Rs.” across a price list. Matching is done on the exact characters you type, and case options simply have no effect on scripts like Devanagari that have no capital letters. If a Hindi word looks identical but is not found, it may be typed with a different combination of characters (for example with a nukta or a different form of anusvara); copy the word from the text itself into the Find box to be sure.
Everyday Uses
- Updating a company, product or person's name throughout a document.
- Fixing a repeated typo in a long article.
- Changing URLs or domains in a list of links.
- Cleaning exported data — extra spaces, stray symbols, inconsistent formats.
- Reformatting dates, phone numbers and codes.
- Preparing lists for CSV, SQL or code with prefixes, suffixes and separators.
- Personalising template text by replacing placeholders like {name}.
Common Mistakes to Avoid
- Replacing short words without Whole words — replacing “is” would also change “this” and “island”.
- Forgetting regex special characters — in regex mode, . matches any character; write \. for a real full stop.
- Greedy patterns — “.*” can swallow far more than intended; use “.*?”.
- Applying without checking — always glance at the highlighted matches first.
- Expecting \b to work for Hindi — use the Whole words option instead.
Troubleshooting
- “Invalid pattern” — the regex has a syntax error, such as an unclosed bracket; the message explains it.
- “No matches found” — check Match case, Whole words and spelling; try plain mode first.
- “Took too long” — simplify nested repeats like (x+)+ or (.*)*.
- $1 appears literally — $1 only works in regex mode with a captured group in the pattern.
- Undo says nothing to undo — Undo only reverses changes made with Apply to text; the Result box itself never changes your original.
Quick Glossary
- Regex: a regular expression, a pattern describing text.
- Capture group: part of a pattern in brackets, reusable as $1, $2.
- Anchor: ^ or $, matching a position rather than characters.
- Flag: a setting that changes regex behaviour, such as case-insensitive or multiline.
- Catastrophic backtracking: extremely slow matching caused by ambiguous nested repeats.
- Web Worker: a background thread in the browser that can be stopped without affecting the page.
- Escaping: adding a backslash so a special character like . or ? is matched literally.
Why Use This Find & Replace Tool?
It is simple for everyday replacements and powerful for patterns, shows you every match before you commit, keeps an undo history, handles any language with proper whole-word matching and protects your browser from runaway regexes — free and private.
Find & Replace — Key Facts
| Modes | Plain text, whole words or regular expressions |
|---|---|
| Options | Match case, multiline ^ and $ |
| Regex groups | Use $1, $2 … and $& in the replacement |
| Preview | All matches highlighted with a live count |
| Safety | Regex runs in a Web Worker with a 2-second limit |
| Undo | Apply to text with up to 20 undo steps |
Frequently Asked Questions
How do I replace a word everywhere in a text?
Paste the text, type the word in Find and the new word in Replace with. Every occurrence is replaced in the Result box, and the message shows how many matches were found.
Is find and replace case-sensitive?
Not by default — “Example”, “example” and “EXAMPLE” are all found. Tick Match case to find only the exact capitalisation you typed.
What does “Whole words only” do?
It finds the text only when it is a complete word. Searching “cat” with this option finds “cat” but not “category” or “concatenate”. Word boundaries are Unicode-aware, so it also works with Hindi and other languages.
How do I use regular expressions?
Tick Regular expression and type a JavaScript-style pattern. For example \d{10} finds 10-digit numbers and \s+ finds runs of spaces. In the replacement, $1, $2 insert captured groups and $& inserts the whole match.
Can you give a regex replacement example?
To change dates from 2026-10-17 to 17/10/2026, find (\d{4})-(\d{2})-(\d{2}) and replace with $3/$2/$1. To remove extra spaces, find \s{2,} and replace with a single space.
What does the multiline option do?
With ^ and $ matching each line ticked, ^ means the start of any line and $ the end of any line, instead of the start and end of the whole text. Useful for adding a prefix to every line: find ^ and replace with “- ”.
Why did my regex stop with a “took too long” message?
Some patterns with nested repeats, such as (a+)+, can take exponential time on certain text. The tool runs regular expressions in a background worker and stops them after 2 seconds so your browser never freezes. Simplify the pattern and try again.
How do I insert a literal dollar sign?
In plain mode, $ is inserted as written. In regex mode, write $$ in the replacement to get a single $.
Can I undo a replacement?
The original text is never changed until you press Apply to text. After applying, press Undo to go back — up to 20 steps are kept.
Can I replace line breaks?
Yes, with regex mode. Find \n to match line breaks — for example, replace \n with “, ” to turn a list into a comma-separated line.
Is my text uploaded?
No. Everything runs in your browser, including the background worker.
Is Find & Replace free?
Yes. It is free, unlimited and needs no sign-up.
Change Every Match at Once!
Plain, whole-word or regex replacements with a live preview — free and private.
Explore More Prompt Minds Tools
Find & Replace works great alongside our other free tools. Every Prompt Minds tool runs entirely in your browser — no sign-up, no uploads, no watermarks. Browse all free tools.
