Binary Translator

Morse Code Translator

A Morse code translator turns text into dots and dashes and dots and dashes back into text. Type or paste either one below: "SOS" becomes ... --- ... and the same pattern decodes back to SOS. The table is the international Morse code of ITU-R M.1677-1, and everything runs in your browser.

Direction: text to Morse (auto-detected)

Examples

  • Text to Morse: SOS → ... --- ...
  • Text to Morse: Hello world → .... . .-.. .-.. --- / .-- --- .-. .-.. -..
  • Morse to text: .... . .-.. .-.. --- / .-- --- .-. .-.. -.. → HELLO WORLD
  • PARIS = .--. .- .-. .. ... = 50 units with its word gap; at 20 WPM one unit is 0.06 s

How the translator reads and writes Morse

Each letter, digit and punctuation mark has a fixed pattern of short signals (dots) and long signals (dashes). The translator looks every character up in one table, the same table printed at the bottom of this page, so encoding and decoding can never disagree. Letters are case-insensitive, and output is always upper case when you decode.

You can type dots and dashes with the keys . and -, and look-alike characters such as the middle dot and the en dash are accepted too. In automatic mode, input made only of dots, dashes, spaces and slashes is decoded as Morse; anything else is encoded as text. Choose a direction manually if you want to force one, for example to encode a single full stop.

Gaps between letters and words

Morse relies on timing. Inside a letter the pause is 1 unit, between letters it is 3 units, and between words it is 7 units, where a dot lasts 1 unit and a dash 3. In writing, the common convention is a single space between letters and a slash between words, which is the default output here. The other style writes the 3 and 7 unit gaps as 3 and 7 spaces.

When decoding, the tool accepts a slash, a vertical bar, a line break or a run of seven or more spaces as a word gap, and any shorter run of spaces as a letter gap. Procedural signals such as the error signal (eight dots) are written in angle brackets, for example <HH>, <AS> for wait and <SK> for end of work.

Playing the sound and choosing a speed

The play button sounds the message as a steady tone using the Web Audio API of your browser. Speed is set in words per minute by the PARIS standard: the word PARIS, with its trailing word gap, is exactly 50 units long, so one unit lasts 1.2 divided by the WPM, in seconds. At 20 WPM a dot is 0.06 seconds.

Characters Morse does not define

International Morse code has no codes for accented letters, the exclamation mark or most symbols. The translator skips such characters and lists them under the output rather than guessing. In the other direction, a pattern that is not in the table is shown as the replacement character and reported.

International Morse code table

letters

Morse letters
CharacterMorseMeaning
A.-Letter A
B-...Letter B
C-.-.Letter C
D-..Letter D
E.Letter E
F..-.Letter F
G--.Letter G
H....Letter H
I..Letter I
J.---Letter J
K-.-Letter K
L.-..Letter L
M--Letter M
N-.Letter N
O---Letter O
P.--.Letter P
Q--.-Letter Q
R.-.Letter R
S...Letter S
T-Letter T
U..-Letter U
V...-Letter V
W.--Letter W
X-..-Letter X
Y-.--Letter Y
Z--..Letter Z

digits

Morse digits
CharacterMorseMeaning
0-----Digit 0
1.----Digit 1
2..---Digit 2
3...--Digit 3
4....-Digit 4
5.....Digit 5
6-....Digit 6
7--...Digit 7
8---..Digit 8
9----.Digit 9

punctuations

Morse punctuations
CharacterMorseMeaning
..-.-.-Full stop (period)
,--..--Comma
:---...Colon
?..--..Question mark
'.----.Apostrophe
--....-Hyphen or minus
/-..-.Fraction bar or slash
(-.--.Left-hand bracket
)-.--.-Right-hand bracket
".-..-.Inverted commas (quotation mark)
=-...-Double hyphen (equals sign)
+.-.-.Cross (plus sign), also the AR signal
@.--.-.Commercial at

Procedural signals

Morse prosigns
CharacterMorseMeaning
<VE>...-.Understood
<HH>........Error (eight dots)
<AS>.-...Wait
<SK>...-.-End of work
<KA>-.-.-Starting signal

Frequently asked questions

What standard does this Morse table follow?
It follows Recommendation ITU-R M.1677-1, "International Morse code", which lists the letters, figures, punctuation marks and procedural signals.
How long is a dot, a dash and a gap?
A dot is 1 unit and a dash is 3 units. The gap inside a letter is 1 unit, between letters 3 units and between words 7 units.
How do words per minute map to seconds?
By the PARIS standard one unit lasts 1.2 / WPM seconds, so 12 WPM gives 0.1 seconds per unit and 20 WPM gives 0.06 seconds.
Why is a character missing from the output?
It has no code in ITU-R M.1677-1, for example é or !. The tool skips it and names it in a message below the output.

Standards and references