How this instrument works
Parity checking is a basic error-detection scheme: alongside a block of data bits, you send one extra 'parity bit' chosen so that the total count of 1-bits, data plus parity together, always follows a fixed rule. In even parity, that rule is that the total must always be even. If the receiver counts the 1-bits it received and gets an odd number, it knows at least one bit flipped in transit — a single-bit error has been caught.
Generating the even-parity bit is simple arithmetic: count how many of the data bits are 1. If that count is already even, the parity bit is 0 (adding nothing keeps the total even). If the count is odd, the parity bit is 1 (adding one more 1 flips the odd total to even). Either way, data-plus-parity always lands on an even count of 1s — that's the entire scheme.
Even parity has been used since the earliest days of digital data transmission and storage — old RS-232 serial links, early RAM modules, and many low-level communication protocols used a parity bit exactly like this one to catch single-bit corruption cheaply, at the cost of just one extra bit per data word. It can't catch every error (two flipped bits cancel out and the parity still checks even), but it catches the single most common failure mode in noisy channels for almost no overhead.
This instrument works with an 8-bit data word, the most common byte-oriented size for teaching and for real serial-port parity settings. Toggle any bit and the parity bit updates immediately, showing exactly how the 4-2-1-style summation logic of digital circuits turns raw data into a self-checking package.
- Toggle Bit 1 through Bit 8 to 0 or 1 to represent the data byte you want to protect.
- Read Number of 1-bits in the data to see how many bits are currently set high.
- Read Even parity bit — this is the bit you'd append (or transmit alongside the byte) so the total 1-count, including this bit, is even.
- If you're checking a received byte plus its parity bit for corruption, enter the received data bits here and compare: if the computed parity bit doesn't match the one that arrived, an odd number of bits were flipped.
- Try an all-zero byte and an all-one byte to see the two edge cases where the parity bit is 0 even though the data itself looks very different.
Worked example — data byte 1,1,0,1,0,0,0,0
Set bit1=1, bit2=1, bit3=0, bit4=1, bit5=0, bit6=0, bit7=0, bit8=0. Number of 1-bits in the data reads 3 — an odd count. Even parity bit reads 1, because adding one more 1 to an odd count of 3 brings the total to 4, which is even.
If this byte plus its parity bit (1,1,0,1,0,0,0,0,1) were transmitted and the receiver recounted the 1s across all nine bits, it would get 4 — even, as expected, so no single-bit error is flagged. If instead any one of those nine bits flipped in transit, the receiver's recount would land on an odd total (3 or 5), immediately signalling that something went wrong.
Questions
What is even parity used for?
Even parity is a lightweight error-detection scheme: one extra bit is added to a block of data so the total number of 1-bits, data plus parity, is always even. If a receiver recounts the 1s and gets an odd total, it knows at least one bit was corrupted in transmission or storage. It was widely used in early serial communication (RS-232 parity settings), some RAM modules, and other low-level protocols where cheap, basic error detection mattered more than correction.
How do you calculate the even parity bit?
Count the number of 1-bits in the data. If that count is even, the parity bit is 0. If the count is odd, the parity bit is 1. Either way, appending the parity bit makes the total count of 1s (data plus parity) even. For example, data 1,1,0,1,0,0,0,0 has three 1-bits (odd), so the parity bit is 1, bringing the total to four (even).
What errors can even parity catch, and what does it miss?
Even parity reliably catches any single-bit flip, because flipping exactly one bit always changes the total 1-count's evenness. It cannot catch an even number of bit flips (two, four, and so on), because those cancel out and the total 1-count stays even, so the corrupted data passes the check undetected. That's why parity is called an error-detection scheme, not an error-correction scheme — it flags likely single-bit corruption but can't fix it or catch every possible error pattern.
What's the difference between even parity and odd parity?
Both add one extra bit to a data block, but they target opposite totals: even parity sets the bit so the total count of 1s (data plus parity) is always even, while odd parity sets it so that total is always odd. For the same data, the two schemes almost always produce opposite parity bits — this site's separate odd-parity instrument computes the odd-parity version of the same calculation, and both agree only when a system is configured to use one convention consistently end to end.
Why does an all-zero byte have an even parity bit of 0?
An all-zero byte already has zero 1-bits, and zero is an even number, so no extra 1 is needed to keep the total even — the parity bit is 0. The all-ones byte (eight 1-bits) works out the same way: eight is already even, so its even-parity bit is also 0, even though the data itself is completely different from the all-zero case.