Text Replace Online

Find and replace words, phrases, or patterns in your text with advanced options including regular expression support

Replacement Options

Regex help: Use special characters like .*+?()[]{}| for advanced patterns. Learn more about Extract Text Using Regular Expressions.

Ready to replace. Enter find/replace text, configure options, and click "Replace Next" or "Replace All".

How to Use This Text Replace Tool

  1. Enter find and replace text:
    • In the "Find" field: Enter the text, word, or pattern you want to locate
    • In the "Replace with" field: Enter what you want to replace it with (can be empty)
  2. Paste your text into the "Text to process" input box.
  3. Configure replacement options:
    • Case sensitive: Makes the search case sensitive (e.g., "Cat" won't match "cat")
    • Use regular expressions: Enables advanced pattern matching with regex syntax
    • Replace all occurrences: Automatically replaces every match when enabled
  4. Perform replacements:
    • Replace Next: Replaces only the next occurrence of the pattern
    • Replace All: Replaces every occurrence of the pattern
  5. Use your modified text: Copy it to your clipboard, download as a text file, or try different replacement patterns.

Replacement Options Explained

Basic Replacement Example:

Find: cat
Replace with: dog
Original: The cat chased the other cat.
Result: The dog chased the other dog.

Case Sensitive Example:

Find: Cat (with case sensitive enabled)
Replace with: Dog
Original: Cat, cat, CAT
Result: Dog, cat, CAT

Replace All Occurrences Example:

Find: quick (with replace all enabled)
Replace with: fast
Original: The quick fox and quick rabbit
Result: The fast fox and fast rabbit

Regular Expression Example:

Find: \b\d{3}-\d{2}-\d{4}\b (SSN pattern with regex enabled)
Replace with: [REDACTED]
Original: My SSN is 123-45-6789.
Result: My SSN is [REDACTED].

Common Uses for Text Replacement

The text replace tool is versatile for many scenarios:

  • Editing documents: Quickly fix consistent errors or update terminology
  • Formatting text: Standardize spacing, capitalization, or punctuation
  • Data cleaning: Remove or redact sensitive information like emails or phone numbers
  • Code refactoring: Rename variables or functions throughout a codebase
  • Content repurposing: Adapt existing content for different contexts
  • SEO optimization: Replace keywords or adjust phrasing in website content
  • Language processing: Perform consistent transformations on text for analysis