Overview
Introduction
Swapping every occurrence of one specific letter for another is a small but common text-editing task, from stylizing text to simple substitution ciphers.
This tool runs entirely client-side, so nothing you paste is ever uploaded to a server.
What Is Letter Replacer?
A letter-level replacement tool that swaps every occurrence of a single target letter for a single replacement letter throughout your text.
It's part of this site's String Tools collection and works entirely in your browser, updating the result instantly as you change the target or replacement letter.
How Letter Replacer Works
The tool walks through the input character by character, comparing each one case-insensitively against the target letter.
When a character matches, it's swapped for the replacement letter, adjusted to uppercase or lowercase to match the original matched character's case; non-matching characters pass through unchanged.
When To Use Letter Replacer
Use it to swap a specific letter throughout a text sample, such as replacing every 'o' with '0' for a stylized effect.
It's also useful for building or testing a simple single-letter substitution pattern without writing a script.
Often used alongside Find & Replace Tool and Case Converter.
Features
Advantages
- Preserves the original case of every matched occurrence individually.
- Simple, predictable one-letter-for-one-letter substitution.
Limitations
- Only supports a single target letter and single replacement letter per run; it can't swap multiple letter pairs at once.
Examples
Best Practices & Notes
Best Practices
- Run the tool multiple times in sequence if you need to swap several different letter pairs.
Developer Notes
Both `target` and `replacement` are validated to be exactly length 1 before processing; the transform is `Array.from(input).map((char) => char.toLowerCase() === lowerTarget ? (isUpper ? replacement.toUpperCase() : replacement.toLowerCase()) : char).join("")`.
Letter Replacer Use Cases
- Swapping a specific letter for a stylized character, like 'o' for '0'
- Testing a simple single-letter substitution pattern
- Correcting a consistently mistyped letter throughout a text sample
Common Mistakes
- Entering more than one character in the target or replacement field; both must be exactly one character.
- Expecting whole-word replacement; this tool operates on individual letter occurrences, not words.
Tips
- Use a digit or symbol as the replacement to create a simple leetspeak-style substitution effect.