Morse Code Translator
Translate text to Morse code and back with audio playback, visual flash sync, and adjustable speed. Follows ITU-R M.1677-1 standard with Web Audio oscillator.
How to Use
This tool translates between plain text and International Morse Code in real-time. Every keystroke updates the output instantly, and the built-in audio engine lets you hear the actual signal pattern through your speakers or headphones.
Encode Text to Morse Code
- Select the Text to Morse mode using the segmented control at the top.
- Type or paste your message into the input field. Letters, numbers, and supported punctuation are converted instantly.
- The Morse output appears below using dots (
.) and dashes (-), with spaces between characters and slashes between words. - Click the Copy button to copy the Morse string to your clipboard.
Decode Morse Code to Text
- Switch to Morse to Text mode.
- Enter Morse code using dots and dashes. Separate letters with spaces and words with forward slashes (
/). For example:.... . .-.. .-.. --- / .-- --- .-. .-.. -..decodes to "HELLO WORLD". - The decoded plain text appears in real-time as you type.
Play Audio
- After entering text or Morse, click the Play Audio button to hear the signal.
- Adjust Speed (WPM) to control how fast the dots and dashes play. Higher WPM produces shorter time units.
- Change the Frequency slider to alter the tone pitch — 700 Hz is the standard CW tone used in amateur radio.
- Use the Volume slider to set the output level from silent to full.
- Watch the green flash indicator pulse in sync with each dot and dash during playback.
About This Tool
Morse code is a character encoding scheme that represents text as sequences of short signals (dots) and long signals (dashes). Invented by Samuel Morse and Alfred Vail in 1838 for use with the electric telegraph, it was the first practical method of long-distance electrical communication. The original American Morse Code was later replaced by the International Morse Code standard, now governed by the ITU-R M.1677-1 recommendation.
ITU-R M.1677-1 Standard
The International Telecommunication Union maintains the definitive Morse code specification under recommendation ITU-R M.1677-1. This standard defines the exact dot-dash sequences for 26 Latin letters, 10 Arabic numerals, and a set of punctuation marks and procedural signals. Each character has a unique code — for example, the letter E is a single dot (the shortest code), while 0 (zero) is five dashes (the longest standard code). The frequency of letters in English influenced the original code assignments: common letters like E, T, A, and I received shorter codes to speed up transmission.
PARIS Timing Standard
Morse code speed is measured in words per minute (WPM) using the word "PARIS" as the reference. "PARIS" requires exactly 50 time units to transmit (including the trailing word space), so at N WPM the dot duration equals 1200 / N milliseconds. A dash lasts three dot-lengths. Within a character, symbols are separated by one dot-length of silence. Between characters, three dot-lengths of silence. Between words, seven dot-lengths. At the default 20 WPM, one dot lasts 60 milliseconds, producing a recognizable rhythmic cadence.
Web Audio API Implementation
This tool generates audio entirely in the browser using the Web Audio API. An OscillatorNode produces a pure sine wave at the selected frequency, connected through a GainNode that shapes the amplitude envelope. The gain ramps from zero to full volume in 5 milliseconds (attack) and back to zero in 5 milliseconds (decay), eliminating the audible clicks that occur with abrupt start/stop transitions. No audio files are downloaded or streamed — every tone is synthesized mathematically at sample-level precision.
History of Morse Code
Samuel Morse demonstrated the first practical electric telegraph in 1838, sending messages as electrical pulses along copper wire. By 1844, the first long-distance telegraph line connected Washington D.C. to Baltimore. The original American Morse Code used variable-length dashes and internal spaces, making it complex to learn. In 1865, the International Telegraph Conference in Paris adopted a simplified version that became International Morse Code, eliminating internal spaces and standardizing all dashes to a uniform length. Morse code remained the primary means of maritime communication until 1999, when the Global Maritime Distress and Safety System replaced it. The famous SOS distress signal (... --- ...) was adopted in 1906 for its unmistakable rhythmic pattern.
Why Use This Tool
Morse code remains relevant in multiple domains, from amateur radio to emergency preparedness. Here are the primary reasons people use a Morse code translator:
- Amateur radio (ham radio) — Morse code, known as CW (continuous wave) in radio terminology, remains one of the most efficient communication modes. CW signals can be decoded at signal-to-noise ratios far below what voice requires, making it invaluable for long-distance contacts. A CW signal occupies only 150 Hz of bandwidth compared to 2,400 Hz for voice (SSB). Many amateur radio operators practice Morse daily, and CW-only contests attract thousands of participants worldwide.
- Education and learning — Students learning Morse code benefit from seeing the visual translation alongside audio playback. Adjustable WPM lets beginners start slow (5 WPM) and gradually increase speed as they build proficiency. The Farnsworth method, where character speed is faster than overall spacing, can be practiced by adjusting the WPM setting.
- Emergency communication — The SOS distress signal (
... --- ...) can be transmitted using a flashlight, mirror, whistle, or any device capable of producing on/off signals. Search and rescue teams and military personnel learn Morse as a backup communication method that requires no special equipment. - Accessibility — Morse code serves as an assistive input method. Google's Gboard keyboard supports Morse code input on Android and iOS, allowing people with motor disabilities to type using as few as two switches (dot and dash). This tool helps users learn the patterns needed for switch-based input.
- Puzzles and escape rooms — Morse code frequently appears in escape rooms, geocaching challenges, CTF cybersecurity competitions, and educational exercises about encoding theory. This translator lets users verify solutions or encode custom puzzle clues.
- Embedded systems and IoT — Microcontrollers like Arduino and ESP32 commonly use LED blink patterns or buzzer tones to communicate status codes in Morse. Developers use this tool to generate the correct dot/dash sequences for their firmware.
Privacy
All encoding, decoding, and audio generation happen entirely in your browser. No text is transmitted to any server. The Web Audio API synthesizes sound locally, and the Morse lookup table is a static JavaScript object bundled with the page. Your messages remain private on your device.