digtools
🔤
mojibake fixer,

Mojibake Fixer & Encoding Converter

Fix garbled text (Mojibake) instantly. A browser-based text encoding converter.

🔒️
In-Browser Processing
Nothing is sent to a server
⚡️
No Signup Required
Use instantly without creating an account
✨️
Instant Recovery
Paste text to see all encoding conversions

Text to Restore

0 chars
Drop file to load
about,

Mojibake Fixer Tool Overview

This free online tool automatically restores garbled (Mojibake) text back to its original, readable form just by pasting it. Whether you received scrambled characters from a file transfer between Windows and Mac, or extracted corrupted data from a legacy system, this tool resolves text encoding issues instantly.

It auto-detects and tests all conversion patterns between UTF-8, Shift_JIS (SJIS / CP932), EUC-JP, and ISO-2022-JP, then presents the most natural, coherent result — saving you the hassle of manually guessing which character encoding was used.

All restoration processing runs entirely inside your browser. Your sensitive data, including confidential documents and customer information, is never transmitted to or stored on any external server. No software installation, account creation, or login is required — making it safe and private enough for everyday business use.

cause,

Why Does Mojibake Happen? Common Causes Explained

Character Encoding Mismatch Is the Root Cause

On a computer, all text data is stored as a sequence of numbers (bytes — zeroes and ones). The rulebook that maps these numbers to human-readable characters is called a "character encoding" (such as UTF-8 or Shift_JIS).

For example, the same Japanese character "あ" is represented by completely different byte values in UTF-8 versus Shift_JIS. If the sender saves a file using Shift_JIS, but the receiver's software mistakenly opens it as UTF-8, the bytes are interpreted with the wrong rulebook — and the screen displays garbage characters instead. This is Mojibake.

Common Mojibake Patterns

  • UTF-8 misread as Shift_JIS:
    The most common type of mojibake on the web. You'll see unfamiliar kanji like "繧", "縺", and "繝" appearing in long, nonsensical strings. This frequently happens when a file created on Mac is opened with older Windows software.
  • Shift_JIS misread as UTF-8:
    Most characters are replaced with "�" (the black diamond with a question mark) or literal "?" marks. If the text was saved after this replacement occurred, the original byte data is permanently lost, making full recovery impossible.
how to,

How to Fix Mojibake — Step-by-Step Guide

STEP 1

Paste the Garbled Text

Paste the scrambled text you want to decode into the input area above. You can also drag & drop text files (.txt, .csv) with broken encoding directly into the tool.

STEP 2

Choose the Correct Result

Dozens of encoding conversion patterns are automatically tested in the background. Browse the results and look for the one with the "★ Recommended" badge — it indicates the most naturally readable Japanese text.

STEP 3

Copy or Try Manual Conversion

Click the "Copy" button on the correctly restored result to save the clean text to your clipboard. If auto-detection doesn't produce the right result, use the "Manual Encoding Conversion" panel to specify the exact encoding pair yourself.

glossary,

Mojibake & Encoding Glossary

Mojibake (Garbled Text)
An error phenomenon where the character encoding used to create and save a text file does not match the encoding used to open and read it, causing characters to display as garbled, nonsensical symbols (e.g., "縺ゅ>縺"). A character code conversion tool is needed to restore the correct encoding.
UTF-8 (Unicode Transformation Format)
The most widely adopted character encoding standard on the modern internet and in operating systems (a variant of Unicode). It can handle characters from virtually all languages simultaneously, but is frequently misread as Shift_JIS by older Windows software, causing mojibake.
Shift_JIS (SJIS / CP932)
A legacy character encoding specific to the Japanese language, widely used in older Windows OS environments. Opening modern UTF-8 text in a Shift_JIS-only application (such as older versions of Excel) produces the distinctive "縺" mojibake pattern.
EUC-JP / ISO-2022-JP
EUC-JP was commonly used on older Linux and Unix servers. ISO-2022-JP (also known as JIS encoding) was the standard for early Japanese email communications. Both remain sources of mojibake when interfacing with modern systems.
Encode
The process of converting human-readable text into a sequence of bytes (digital data) according to a specific character encoding standard such as UTF-8 or Shift_JIS, so that computers can store and process it.
Decode
The reverse process: converting byte data back into human-readable text according to a character encoding rulebook. When the wrong rulebook is applied during decoding, mojibake appears on screen.
faq,

Frequently Asked Questions About Mojibake

Q.Is my text sent to a server?
No. All processing happens entirely in your browser. Data is never sent or stored on any external server, making it safe to decode confidential work emails.
Q.Can I fix CSV file mojibake?
Yes. Drag & drop the garbled CSV file or select it via the Load File button. After restoring with this tool, save it as UTF-8 with BOM in a text editor so it opens correctly in Excel.
Q.Why do some texts fail to recover?
If the scrambled text was re-saved in a destructive format (like ANSI/Windows-1252), missing byte information is permanently lost. Irreversible mojibake cannot be mathematically fixed, although this tool attempts to estimate parts of it.
Q.What does a pattern like 'UTF-8 → Shift_JIS' mean?
It represents the 'mistake' that caused the garbled text: The original document was saved in 'UTF-8', but the software you are using erroneously opened it assuming it was 'Shift_JIS'.
Q.How do I know which of the output results is the correct one?
The tool shows attempts from all common encoding combinations. Simply scroll through the output panel and visually identify the block where the Japanese characters become a coherent, legible sentence.
Q.Can this fix the common '縺' scrambling issue?
Yes. The occurrence of characters like '縺' is the hallmark of UTF-8 text incorrectly opened as Shift_JIS. Our tool easily translates this back to correct Japanese.
Q.Can it recover emoji that turned into question marks (?)
Generally, no. If the software did not support emojis and overwrote the 4-byte characters with an actual '?' or '□' character, the original data is destroyed and cannot be recovered.
Q.How can I prevent Mojibake from happening to my team?
Ensure all team members set their text editors, IDEs, databases, and CSV export settings to use the universal 'UTF-8' standard to eliminate encoding mismatches entirely.
use cases,

Common Mojibake Scenarios & Solutions

Here are the most common situations where mojibake occurs, along with practical solutions.

📂

CSV Files Garbled When Opened in Excel

When you open a UTF-8 encoded CSV file (e.g., exported from a web application) by double-clicking it in Windows Excel, Excel may try to read it as Shift_JIS, causing mojibake.

Solution: Drop the file into this tool to restore it, or use Excel's "Data" tab → "From Text/CSV" import wizard and specify UTF-8 as the file origin encoding.

📧

Received Emails Are Unreadable

This happens when the sender's email client uses an older encoding like ISO-2022-JP or EUC-JP, but the recipient's mailer (Outlook, Gmail, etc.) tries to process it as UTF-8.

Solution: Copy the entire garbled email body and paste it into this tool's input area to decode and restore the original message.

🗜️

ZIP File Names Garbled Between Mac & Windows

When a ZIP file created on Mac is extracted on Windows using the built-in extractor, file names may become garbled. This is because Mac stores file names in UTF-8, while Windows tries to interpret them as Shift_JIS.

Solution: Use a UTF-8-aware extraction tool like 7-Zip, or use a Windows-compatible compression utility on the Mac side.

🌐

Entire Website Appears Garbled in Browser

This occurs when the HTML file's meta tag (charset declaration) doesn't match the actual encoding the file was saved in.

Solution: Use a browser extension to manually change the text encoding, or the site administrator needs to correct the charset declaration in the HTML.

technology,

How the Mojibake Recovery Algorithm Works (Technical Details)

Secure, Browser-Native Processing via TextDecoder API

To restore mojibake, this tool leverages the TextEncoder and TextDecoder APIs built into modern browsers. It extracts the code points from the garbled input text and performs byte conversion and re-decoding across all supported encodings — entirely on the client side.

This means no data is ever sent to an external server, making the repair process extremely secure and fast.

Brute-Force Auto-Detection & Scoring

For any given input, the tool runs dozens of conversion tests asynchronously in the background:

  • Single-stage conversion (19 patterns): Covers all common mojibake caused by a single encoding misinterpretation (e.g., data that was actually UTF-8 but was opened as Shift_JIS).
  • Multi-stage / double-mojibake (10 patterns): Tackles complex cases where data passed through multiple systems and was misconverted two or more times (e.g., SJIS → CP1252 → UTF-8 chain corruption).

Every result is scored using a proprietary algorithm that evaluates the frequency of Japanese characters (hiragana, katakana, common kanji), the ratio of ASCII characters, and the prevalence of corrupted replacement characters (? or �). The result with the highest score — deemed the most "natural Japanese" — receives the "★ Recommended" badge.

Send Feedback

Please let us know your thoughts to help us improve the tool.

Disclaimer

The tools provided on this site are completely free to use, but please use them at your own risk. We make no guarantees regarding the accuracy, completeness, or safety of any calculation results, conversion results, or generated data. Please be aware that the operator assumes no responsibility for any damages or troubles caused by the use of these tools. Most tools process files and calculations locally in your browser, meaning your inputted data is neither sent to nor stored on our servers.