Emoji Text Replacement
Replace common English words with matching emojis to make your text more expressive.
Emoji Dictionary (sample)
About this tool
Emoji Text Replacement is a simple yet fun way to add visual expression to your writing by substituting common English words with their matching emoji equivalents. Whether you're crafting social media posts, chat messages, or casual emails, this tool instantly transforms your text into a more colorful and engaging format that captures attention and conveys emotion more vividly.
To use it, simply paste or type your text into the input field, and the tool automatically replaces eligible words with emojisโsuch as "love" becoming โค๏ธ, "sun" becoming โ๏ธ, or "pizza" becoming ๐. You can copy the result directly to use in messages, posts, or documents. The replacement is selective and context-aware, so only clear noun replacements are made, preserving the readability of your message.
This tool works best for informal communication where emoji use is natural and encouraged, such as social media comments, text messages, or friendly emails. Keep in mind that not every word has a direct emoji equivalent, so some less common words may remain unchanged. The tool respects your original text's structure, ensuring that capitalization and punctuation are preserved.
Frequently Asked Questions
Code Implementation
import re
EMOJI_MAP = {
"sun": "โ๏ธ", "moon": "๐", "star": "โญ", "heart": "โค๏ธ",
"fire": "๐ฅ", "water": "๐ง", "tree": "๐ณ", "flower": "๐ธ",
"house": "๐ ", "car": "๐", "book": "๐", "music": "๐ต",
"food": "๐", "coffee": "โ", "dog": "๐ถ", "cat": "๐ฑ",
"money": "๐ฐ", "time": "โฐ", "phone": "๐ฑ", "computer": "๐ป",
"love": "๐", "happy": "๐", "sad": "๐ข", "angry": "๐ ",
"eyes": "๐", "hand": "๐", "thumbs up": "๐", "party": "๐",
"snow": "โ๏ธ", "rain": "๐ง๏ธ", "lightning": "โก", "wind": "๐ฌ๏ธ",
}
def replace_with_emojis(text: str) -> str:
"""Replace words in text with matching emojis."""
def replace_word(match):
word = match.group(0)
return EMOJI_MAP.get(word.lower(), word)
# Build pattern from longest to shortest to handle multi-word mappings
pattern = r"\b(" + "|".join(
re.escape(k) for k in sorted(EMOJI_MAP.keys(), key=len, reverse=True)
) + r")\b"
return re.sub(pattern, replace_word, text, flags=re.IGNORECASE)
text = "I love the sun, the moon, and the stars. My heart is on fire!"
result = replace_with_emojis(text)
print(result)
# Output: I โค๏ธ the โ๏ธ, the ๐, and the โญ. My โค๏ธ is on ๐ฅ!Comments & Feedback
Comments are powered by Giscus. Sign in with GitHub to leave a comment.