Skip to content
Omnikalc

Parity bit calculator: compute and check the parity bit of a byte

Enter a byte as a decimal number, choose even or odd parity and get the binary form, the number of ones, the parity bit to send and a check of a received parity bit.

Updated on
Your inputs

Value out of range

Results

Parity bit to send

1

Check of the received parity bit (1 = valid, 0 = error)

1

The received parity bit matches: no single-bit error detected
Binary value (8 bits, leading zeros not shown)
10,110,101
Bits set to 1 in the data
5

A parity bit is the simplest error check in digital communication: one extra bit that makes the number of ones even or odd. This parity bit calculator converts a byte to binary, counts the ones, gives the parity bit for even or odd parity and checks whether a received parity bit is valid.

How the calculation works

  • Binary form: write the byte as eight bits, for example 181 = 10110101.
  • Count the ones in the data. 10110101 has five.
  • Even parity: the parity bit makes the total number of ones, parity bit included, even. With five ones in the data the bit is 1, giving six.
  • Odd parity: the parity bit makes the total odd. With five ones the bit is 0.
  • Check: the receiver counts the ones in the data plus the parity bit. If the parity does not match, an odd number of bits has changed in transit.

Example

The byte 181 is 10110101 in binary and has 5 bits set to 1. With even parity the parity bit is 1, so the transmitted word has six ones. If the receiver gets the data with a parity bit of 1, the check passes, and with a parity bit of 0 it reports an error.

Why it matters

Parity is the first error-detection scheme taught in computer networking and embedded systems, and it is still used in serial ports and memory. Computing it by hand for each byte is slow and easy to get wrong, especially for odd parity, so a calculator helps when you debug a serial line, build a protocol exercise or check a textbook example.

Good to know

One parity bit catches all single-bit errors and any odd number of flips, but misses an even number of flipped bits, which is why it is weak on noisy links. It detects an error without locating or fixing it. Serial settings are written as 8E1, 8O1 or 8N1 for eight data bits, even, odd or no parity and one stop bit. For files and network packets, checksums and CRCs give much stronger protection.

The hash collision calculator estimates the chance of duplicate identifiers, the subnet calculator splits IP networks and the Ethernet overhead calculator shows how much of a frame is payload.

Frequently asked questions

What is a parity bit?

It is an extra bit added to a group of data bits so that the total number of ones is even or odd. The receiver recounts the ones and spots a transmission error if the parity is wrong.

What errors can a parity bit catch?

Any odd number of flipped bits, which includes every single-bit error. It cannot detect two bits flipping at once, and it cannot say which bit is wrong or correct the error.

What is the difference between even and odd parity?

With even parity the total number of ones, parity bit included, is even, and with odd parity it is odd. Both give the same protection, and the two ends of a link simply have to agree.

Where is parity used?

Serial links such as UART, memory modules, RAID level 5 and simple storage protocols. Stronger codes such as CRC, Hamming codes and ECC memory are used when errors must also be corrected.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.