ROT13 (Rotate13) Cipher is a simple letter substitution cipher that replaces a letter with the 13th letter after it in the Latin alphabet. ROT13 Cipher is a special case of the Caesar Cipher which was developed in ancient Rome.
Because there are 26 letters (2×13) in the basic Latin alphabet, ROT13 is its own inverse; that is, to undo ROT13, the same algorithm is applied, so the same action can be used for encoding and decoding. The algorithm provides virtually no cryptographic security, and is often cited as a canonical example of weak encryption.
The ROT13 cipher offers almost no security, and can be broken very easily. Even if an adversary doesn't know a piece of ciphertext has been enciphered with the ROT13 cipher, they can still break it by assuming it is a substitution cipher and determining the key using hill-climbing. The ROT13 cipher is also an Caesar cipher with a key of 13, so breaking it as a Caesar cipher also works.
ROT13 was used in online forums as a means of hiding spoilers, punchlines, puzzle solutions, and offensive materials from the casual glance. ROT13 has inspired a variety of letter and word games online, and is frequently mentioned in newsgroup conversations. [Wikipedia]
ROT13 Cipher is essentially a substitution cipher with a fixed key, if you know the cipher is ROT13, then no additional information is needed to decrypt the message. The substitution key is:
ABCDEFGHIJKLMNOPQRSTUVWXYZ NOPQRSTUVWXYZABCDEFGHIJKLM
To encipher a message, find the letter you wish to encipher in the top row, then replace it with the letter in the bottom row. In the example below, we encipher the message 'ATTACK AT DAWN'. The first letter we wish to encipher is 'A', which is above 'N', so the first ciphertext letter is 'N'. The next letter is 'T', which is above 'G', so that comes next. The whole message is enciphered:
ATTACK AT DAWN NGGNPX NG QNJA
To decipher a message, the exact same procedure is followed. Find 'N' in the top row, which is 'A' in the bottom row. Continue until the whole message is deciphered.