Find & Replace

Advanced text find and replace tool with regex support, case sensitivity options, whole word matching, batch replacements, preview mode, and replacement history. Process text instantly in your browser.

Find and Replace Options

0 matches
Use $1, $2 for regex groups
Batch Replace 0 rules

Text Editor

Import from Google

Paste a public Google Docs, Sheets, or Slides link below.

Docs Sheets Slides
Live Preview
100% Private

Replace History

No replacements yet

Common Find & Replace Examples

Remove Double Spaces Find: [space][space] → Replace: [space]
Remove Blank Lines (Regex) Find: \n\n+ → Replace: \n
Trim Leading Whitespace Find: ^\s+ → Replace: (empty)
Remove Duplicate Words Find: \b(\w+)\s+\1\b → Replace: $1
Mask Email Addresses Find: email pattern → Replace: [EMAIL]

Keyboard Shortcuts

F3 Find Next
Shift+F3 Find Previous
Ctrl+H Replace
Ctrl+Shift+H Replace All
Ctrl+Z Undo
Ctrl+Y Redo

Advanced Find and Replace for Text Processing

Our Find and Replace tool goes beyond simple text substitution. With support for regular expressions, case-sensitive matching, whole word search, and batch replacements, you can perform complex text transformations in seconds. Whether you're cleaning data, refactoring code, or editing documents, this tool handles it all with precision.

All processing happens locally in your browser, ensuring complete privacy for sensitive documents. No data is ever sent to servers, and you can work offline after loading the page. Process files up to 50MB with instant results.

How to Use Find and Replace

01

Enter Your Text

Paste text directly, upload a file (TXT, CSV, JSON, etc.), or import from Google Docs. Drag and drop files are also supported.

02

Set Search Options

Configure case sensitivity, whole word matching, regex mode, or multi-line options based on your needs.

03

Enter Find & Replace

Type the text or pattern to find, and the replacement text. Use Preview to see changes before applying.

04

Replace & Export

Click Replace All to apply changes, then copy to clipboard or download the modified text.

Advertisement
Ad

Regular Expression Quick Reference

Character Classes

. Any single character
\d Any digit (0-9)
\w Word character (a-z, A-Z, 0-9, _)
\s Whitespace (space, tab, newline)
[abc] Any of a, b, or c
[^abc] Not a, b, or c

Quantifiers

* 0 or more
+ 1 or more
? 0 or 1 (optional)
{n} Exactly n times
{n,m} Between n and m times
*? Non-greedy (lazy) match

Anchors & Groups

^ Start of line
$ End of line
\b Word boundary
(abc) Capture group
(?:abc) Non-capturing group
a|b a or b (alternation)

Replacement Tokens

$1, $2 Captured groups 1, 2, etc.
$& Entire matched text
$` Text before match
$' Text after match
$$ Literal $ character
\n Newline character

Common Find & Replace Examples

Find Email Addresses

[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}

Matches standard email addresses like user@example.com

Find Phone Numbers

\(?\d{3}\)?[-.\s]?\d{3}[-.\s]?\d{4}

Matches formats like (123) 456-7890 or 123-456-7890

Find URLs

https?://[^\s<>"{}|\\^`\[\]]+

Matches HTTP and HTTPS URLs

Remove Extra Spaces

\s{2,}

Replaces multiple spaces with a single space

Remove HTML Tags

<[^>]+> (empty)

Strips all HTML tags from text

Swap Words

(\w+)\s+(\w+) $2 $1

Swaps two consecutive words

Powerful Features

Regular Expressions

Full regex support with capturing groups, lookahead/lookbehind, quantifiers, and character classes for complex pattern matching.

Batch Replacements

Define multiple find/replace pairs and execute them all at once. Perfect for complex multi-step transformations.

Live Preview

See highlighted matches in real-time as you type. Preview changes before applying to ensure accuracy.

Replace History

Track all your replacements with the ability to undo changes. Never lose your original text.

File Support

Upload and process text files up to 50MB. Supports TXT, CSV, JSON, HTML, and many more formats.

100% Private

All processing happens in your browser. Your text never leaves your device, ensuring complete privacy.

Common Use Cases

Code Refactoring

  • Rename variables across files
  • Update function names
  • Change import paths
  • Fix coding conventions

Data Cleaning

  • Remove unwanted characters
  • Standardize formats
  • Fix encoding issues
  • Clean CSV/JSON data

Document Editing

  • Find and fix typos
  • Replace outdated terms
  • Standardize formatting
  • Update references

Web Development

  • Update URLs en masse
  • Change CSS class names
  • Modify HTML attributes
  • Fix broken links
Advertisement
Ad

Frequently Asked Questions

How do I use regular expressions in find and replace?

Enable the "Regex" option, then enter your regular expression pattern in the Find field. Common patterns include: \d+ (numbers), \w+ (words), [a-z]+ (lowercase letters), .* (any characters). Use capturing groups () and reference them with $1, $2, etc. in the Replace field.

What is whole word matching?

Whole word matching only finds complete words, not partial matches. For example, searching for "cat" with whole word matching will find "cat" but not "category" or "scatter". This is useful when replacing specific terms without affecting similar words.

Can I replace multiple patterns at once?

Yes! Use the Batch Replace feature to define multiple find/replace pairs. Each pair is processed in order, allowing you to perform complex multi-step replacements in a single operation. Click "Add Rule" to add more pairs.

How do I preview changes before applying?

Click the "Preview" button to see highlighted matches in the text. Matches will be highlighted in yellow, and you can see the total count of matches. This helps you verify your pattern before replacing.

Is my text data stored on your servers?

No, all processing happens locally in your browser using JavaScript. Your text never leaves your device, ensuring complete privacy for sensitive documents. The tool works entirely offline after loading.

What file types can I upload?

You can upload text-based files including TXT, CSV, JSON, XML, HTML, MD, PHP, JS, Python, Java, and more. Maximum file size is 50MB. You can also import content directly from Google Docs, Sheets, and Slides.