String vs binary packets

First off, it is important to realize that you can send packets in binary with most all sockets. Though, it is often common for more newbie-oriented programs to send in string. When we talk about sending string and binary packets, the string refers to a series of characters such as "this is a string", while for binary, we use a byte array. Sending larger integers (such as a 4-byte variable), requires us to convert it to a series of bytes and packet it into a buffer before sending it (more on this will be handled in the next section). So to skip all of that, you can just send it as a string.

As both performance and bandwidth usage go, binary packets are best by far. Theres much more you can do with binary then you could every do with string packets. But, like mentioned before, it is a lot harder to use. In a well-designed system, you can allow to send both types of packets without many extra conversions. This is useful for more newbie-oriented open source programs.