This article was co-authored by wikiHow Staff. Our trained team of editors and researchers validate articles for accuracy and comprehensiveness. wikiHow's Content Management Team carefully monitors the work from our editorial staff to ensure that each article is backed by trusted research and meets our high quality standards.
This article has been viewed 105,241 times.
Learn more...
The pigpen code looks like undecipherable alien text, but it is actually an easy and fun code to learn. Also known as the masonic code, pigpen is a substitution cipher, which means that it replaces each letter of the alphabet with a different symbol.[1] Perhaps you have a secret message or just want a fun way to send messages to your friends. Either way, this is a code that is easy to learn and create while being difficult for others to decipher.
Steps
Forming a Basic Code
-
1Draw a crosshatch grid and an X. The crosshatch should look like a number sign ("#") or tic-tac-toe board; it will have two horizontal lines crossed by two vertical lines. There should not be any lines on the outside of the crosshatch. The crosshatch grid will have nine spaces while the X grid will have four. Both the crosshatch and the X should be large enough to fit two letters in each space.
-
2Write two letters of the alphabet in each space. Fill each box and corner of the grids with two letters from the alphabet. The lines immediately surrounding these letters will form the shape of the symbol for each letter.
- Each symbol from the crosshatch grid should be shaped like a closed, two-sided or three-sided rectangle. Each symbol from the X grid should be shaped like a “V”, “<”, “>”, or “^”.[2]
- For example, if the letter "A" is in the top left hand corner of the crosshatch, it will be represented by the “_|” shape. If the letter "U" is in the left corner of the X, it will be represented by a “>” shape.
Advertisement -
3Put a dot in each space to indicate the right letter. The dots are called “pigs,” giving the code its name.[3] The pig indicates which letter in the grid is the letter that corresponds to the written symbol. No dot means the left letter, while a dot means the right one.
- In a grid where A and B are in the top left hand corner, _| is an A whereas _.| is a B.
-
4Rewrite your code in a list. Once you have assigned letters to boxes and dots, it may help to rewrite your code in a list where you clearly assign each letter to its respective shape. This will be your key. Hold on to this. Share it only with those you are entrusting with your code.
- Once you have written your code into a new list, destroy the original key with the grids. If someone discovers your key, they can decipher your writing!
-
5Practice writing in it. The best way to memorize your code is to start writing in it. Try writing a letter to your friend or copy a passage out of a newspaper or book. Replace each letter in your sentence with its corresponding symbol.
- You may need to reference your key at the beginning. As you continue, you will find that you will start memorizing your code.
- A good passage to start with is “The quick brown fox jumps over the lazy dog” as it contains every letter in the alphabet.
Using Multiple Grids
-
1Draw two crosshatch grids and two X grids. In this version of the code, you will create the code using multiple grids. This will randomize the order of the alphabet a little bit more than using one crosshatch and x grid. It also may be a clearer key for you to work with.
- Traditionally, the order of the grids would be crosshatch, X, crosshatch, X or “# X # X.”[4] You can, however, mix up the order as you please to complicate your code. You can write it as “# # X X” or even “X # X #.” Whichever order you choose will determine the order of symbols when you write your substitution code.
-
2Write one letter in each space. You can choose to write this in alphabetical order or, if you want to be extra careful, reverse alphabetical order. In this version, however, there is only one letter in each space.
-
3Place dots in one crosshatch and X grid. One set of each type of grid should be filled with a dot in every space. To clarify, one crosshatch grid and one X grid should have no dots while one crosshatch grid and one X grid should have one dot per space.
-
4Separate your symbols into a list. Like other pigpen codes, the lines immediately surrounding the letters will form the shape of the symbol while the dots/pigs will signal which letter it is. Writing your code out in a list form with each symbol separated will help you keep track of which symbol corresponds with which letter.
Complicating Your Code
-
1Randomize the order of your letters. When creating the code, instead of putting the letters in alphabetical order in the grid, try randomly assigning letters to boxes. This way, people who are familiar with pigpen code will not be able to immediately guess which symbol relates to which letter.
- The more you randomize your code, the more difficult it will be for others to figure it out. If you are using this code to write to your friends, make sure that they have a copy of your cipher.
-
2Replace dots with other symbols. If you use dots, others may recognize your code as a pigpen code immediately. Try replacing the dots with other symbols, such as 0, X, *, or +. Furthermore, if you really want to confuse people, use multiple symbols in coding your grids.
-
3Write three letters instead of two letters in the spaces. If you are using a single grid and X to form your code, you can make the code even more difficult by writing three letters instead of two in each space. While writing in this method, each symbol will consist of zero, one or two dots. Zero is the left letter, one is the middle and two is the right one.
- In this version, you will have extra spaces. You can fill them with numbers, punctuation (!, ?, &) or leave them blank.
-
4Make your numbers into ciphers. The tic-tac-toe cipher is a type of pigpen cipher used for numbers. Draw a crosshatch grid and fill each space with a number. You don’t need to add dots. Simply use the shape formed by the surrounding lines of each number. Replace “0” with an X.[5]
- For example, 101 would appear as _| X _|
Sample Pigpen Code
Warnings
- Don't write the letter "E" too many times otherwise it will make it easier for the unauthorized eyes to guess what it is.⧼thumbs_response⧽
- A pigpen cipher is a simple and common type of substitution code. While those who have never encountered it may find it baffling, be aware that some might recognize this type of code instantly.⧼thumbs_response⧽
References
- ↑ https://www.fbi.gov/about-us/lab/forensic-science-communications/fsc/jan2000/olson.htm
- ↑ https://sites.google.com/site/codesforscouts/pigpen
- ↑ http://press.princeton.edu/chapters/s11_8214.pdf
- ↑ http://www.caesum.com/handbook/ciph1.htm
- ↑ https://www.fbi.gov/about-us/lab/forensic-science-communications/fsc/jan2000/olson.htm