Binary is a numeric system which uses two numerals to represent all real numbers. While the most common counting system, the decimal system, uses ten numerals, binary uses only 0 and 1.
Each digit in a binary number system therefore represents a power of two. The first digit on the right represents the 0th power, the second represents the 1st power, the third represents the 2nd power, and so on. So the number 1 in the decimal system is represented also as 1 in the binary system. The number 23, by contrast, is represented as 10111 (16+0+4+2+1).
The decimal system makes perfect sense for human beings to use. We have ten fingers and ten toes, so when early humans began counting things they turned to these readily available markers. Later, when systems of counting became codified, it was natural to convert the already used decimal system to a representational system. Binary is also a fairly natural system, however, since many things either "are" or "are not." Many spiritualist traditions, such as the Pythagoreans and some Indian mystics, therefore made use of this system, beginning in the 6th century BC.
In 1854, a central paper on binary systems was published by the mathematician George Boole. This paper laid out the groundwork for what would eventually be called Boolean algebra. With the advent of electronics, these systems suddenly made incredible sense. Most electronic systems function on a switch-based system, with current either running or not running. In 1937, Claude Shannon set out the foundations for the theory of circuit design using binary arithmetic. In 1940, the age of binary computing began with the release of Bell Labs Complex Number Computer, which was able to perform extremely complex mathematical calculations using this type of system.
In a more general sense, binary systems can be anything which offers only two options, not necessarily limited to numerical systems. In the case of electronic switches, for example, the system consists of current-no current. A true-false exam is another example. Yes-no questions are also binary in nature.
Mathematical methods exist for transforming binary numbers into decimal numbers, and visa-versa. There are also mathematical devices for performing functions such as addition, subtraction, multiplication and division in different base-systems, including binary. While conversion to or from decimal is somewhat labored, converting between binary and octal or hexadecimal systems, base-eight and base-16 respectively, is much easier. This is because both eight and 16 are powers of two, making them integrate well with binary systems. It is for this reason that both octal and hexadecimal are widely used base-systems in computer applications.