About Find and Replace Text
You paste or type your text, set a Find string and a Replace string, and pick match options. The tool runs entirely in your browser, so nothing is uploaded to a server. Results update instantly as you type, and the page shows the modified text and the number of replacements made. You can copy the result or share a link that reopens the page with your text. Match modes include Exact text, Whole words only, and Regular expression using JavaScript regex syntax. You can also toggle Match case to control letter case. This single-pair tool is fast for quick swaps and simple edits where you want immediate feedback and a copyable result.
How to use it
- 1Paste or type your text into the Your text field
- 2Enter the Find text and the Replace with text
- 3Choose Match mode: Exact text, Whole words only, or Regular expression
- 4Set Match case to Yes or No, then copy or share the Result
Worked example
Input Your text: "cat category cat" Find: "cat" Replace with: "dog" Match: Whole words only Match case: No Result: "dog category dog" Replacements made: 2
How it works
Every match of the Find text is replaced in one pass, left to rightExact text treats every character literallyWhole words only adds word boundaries, so "cat" does not change "category"Regular expression uses JavaScript regex syntax: use $1, $2 in the replacement to reuse captured groups and \n for a new lineResults update instantly as the visitor types; there is no calculate buttonVisitors can copy the result and share a link that reopens with their numbersSource: MDN String.prototype.replaceECMAScript Language Specification (ECMA-262). Last checked 6 November 2026.
What it is good for
- Instant preview and replacement counts as you type
- Runs in your browser so the text is not uploaded
- Supports Exact text, Whole words only and JavaScript regex
- Works on plain text only, not on formatted office files
- Single Find/Replace pair per run; no built-in multi-rule sequencing
Questions people ask
How does the tool perform replacements?
It scans left to right and replaces every match in one pass. Exact matches use literal characters, whole-word adds boundaries, and regex follows JavaScript rules.
Can I use regular expressions?
Yes. Choose Regular expression and use JavaScript regex syntax. Use $1, $2 to reuse capture groups and \n for a new line in the replacement.
Is my text uploaded to a server?
No. The tool runs in your browser, so nothing is sent to a server. If you need absolute legal certainty, check your browser settings and privacy policy.
How do I swap two words safely?
This tool handles one Find/Replace pair at a time. To swap A and B, either run three steps with a unique temporary token, or use a tool that applies pairs simultaneously.
Will it keep capitalization like Color to Colour?
The tool only toggles case sensitivity. To preserve or transform capitalization automatically, use separate rules or a regex with a replacement function in code.
Can I process multiple files or DOCX here?
No. The tool works on plain text you paste or type. For DOCX or XLSX, extract text first or use a dedicated file-aware tool.
Help keep every tool free
FreeToolr stays free because people help it grow. Share a tool you like, tell us what to build next, or support us on Ko-fi.