Data encryption can be done a number of different ways. One way is to use a "dictionary" of substitute symbols(letters, numbers, characters) for existing characters. Dictionaries can be static, or randomly generated. If it is a randomly generated dictionary, the dictionary must be embedded into the encrypted string somehow, thereby increasing the length of the string being sent.
Another technique is "shuffling" the string into a jumble that gets "unshuffled" later on. You can split strings into parts, reverse some of the parts, then reshuffle the string together in a nonstandard fashion.
You can get a relatively good encryption by using either technique, or by combining the techniques together.
There's more you can do, but it sounds like you are looking for a simple encryption, so this should give you some ideas.