Make Arabic read the right way in LTR apps
You paste a clean Arabic phrase into a left-to-right field — a button label, a JSON value, a chat message — and the punctuation jumps to the wrong side or the whole run reverses. The text is fine; the layout engine just resolved its direction wrong. This tool wraps the snippet in the correct invisible Unicode bidi controls so it renders properly wherever you paste it.
How it works
The Unicode bidirectional algorithm decides direction from the characters present and their context. By bracketing your text with explicit control characters, you override that guess for just that run. The tool offers four methods, strongest isolation first:
- RLI…PDI — right-to-left isolate. Sets RTL and hides the run from the outer context (recommended).
- FSI…PDI — first-strong isolate. Direction is taken from the first strong character inside.
- RLE…PDF — legacy RTL embedding. Sets RTL but still interacts with surrounding text.
- RLM marks — lightweight zero-width bracketing for neutral characters.
A live preview renders the wrapped output inside a deliberately left-to-right box so you can confirm the fix before copying.
Tips and notes
Reach for the isolate methods (RLI…PDI or FSI…PDI) first — because they are sealed off from the surrounding text, they fix your Arabic run without accidentally flipping the rest of the line. Use the legacy embedding only when you must support an environment that predates isolates. The RLM bracketing is perfect for the common case where only a trailing parenthesis or period lands on the wrong side. Remember the added characters are invisible, so the copied string is slightly longer than what you see.