Find and replace

Several rules at once, with or without regular expressions

No database: AIMRAN doesn't store your files, text or results

What is Find and replace?

This tool changes words or phrases in a text in one go: replace a name that keeps repeating, fix a typo throughout a document or delete an expression that appears many times.

You can create several rules and they're all applied in sequence. Before copying the result, you see every match highlighted and how many changes each rule makes.

How to use it

  1. Paste the text you want to search and replace in.
  2. Enter what to find and what to replace it with (leave it empty to delete).
  3. If needed, turn on Match case, Whole word or Regular expression.
  4. Click Add rule to make more replacements at once.
  5. Review the highlighted matches and copy or download the final text.

Advantages

Technical details

Each rule becomes a JavaScript regular expression with the g and u flags (plus i unless Match case is on). Without the regular expression option, the search text is escaped so it's treated literally. Whole word uses lookbehind and lookahead assertions with Unicode letter and number classes, so it works correctly with accented letters and ñ (unlike \b). Rules are applied from top to bottom, each on the result of the previous one. In the replacement, \n inserts a line break and, with regular expressions, $1, $2… insert captured groups. Invalid expressions are flagged with their error. The match view highlights up to the first 20,000 characters.

Frequently asked questions

How do I replace a word throughout a text?

Paste the text, type the word in Find and the new one in Replace with. The result appears instantly with every replacement.

Can I do several replacements at once?

Yes. Click Add rule for each replacement; they're applied in order, from top to bottom.

How do I delete a word from a text?

Type it in Find and leave the Replace with field empty.

Does it support regular expressions?

Yes. Turn on the .* button in the rule. You can use groups and reference them with $1, $2 in the replacement.

How do I stop it from replacing part of another word?

Turn on Whole word: that way “cat” won't be changed inside “category”.

More Text & AI tools