In World War II, military leaders used wireless radio communication to pass military messages to troops all over the world. Unfortunately, radio messages could be intercepted. If enemy forces intercepted a message, they would have time to prepare for an attack.
To prevent the enemy from intercepting information, plans and orders were transmitted using secret codes. During World War II, the Germans invented a special machine called "Enigma" to encode their secret messages.
The Allies eventually cracked the German code, thanks to the work of Polish and British mathematicians. In the 1930s, a German traitor gave information to the Allies, which Polish cryptologists used to copy the Enigma machine and solve its letter-scrambling patterns. The Allies gave a special code name to information from decrypted Enigma messages: “ULTRA."
Although cryptology played a key role in World War II, it had been used for centuries before then. In ancient times when important documents and military commands were carried on foot by messenger, kings and rulers would encrypt the letters they sent to troops and allies.