Gray Code to Binary Converter

Convert Gray Code values into binary numbers instantly. Enter a Gray Code sequence and get the equivalent binary output with accurate digital logic conversion.

Binary Result: -
Decimal Result: -
Status: -

What is Gray Code?

Gray Code is a binary numbering system where two consecutive values differ by only one bit. It is also called reflected binary code and is commonly used in digital electronics to reduce errors during transitions.

Binary:

000
001
010
011


Gray Code:

000
001
011
010

How to Convert Gray Code to Binary

To convert Gray Code into binary:

  1. The first binary bit is the same as the first Gray bit.
  2. Each following binary bit is calculated by XORing the previous binary bit with the current Gray bit.
  3. Continue until all bits are converted.
Gray Code:

1101


Step 1:

Binary first bit = 1


Step 2:

1 XOR 1 = 0


Step 3:

0 XOR 0 = 0


Step 4:

0 XOR 1 = 1


Result:

1001

Gray Code Conversion Examples

Gray Code Binary
0000 0000
0001 0001
0011 0010
0110 0100
1101 1001

Gray Code Applications

  • Rotary encoders.
  • Digital position sensors.
  • Analog-to-digital converters.
  • Error reduction in communication systems.
  • Digital circuit design.

Frequently Asked Questions

Gray Code is used in digital systems where reducing transition errors between binary states is important.
The first binary bit remains the same, and every next binary bit is calculated using XOR between the previous binary bit and the current Gray bit.
No. Gray Code and binary are different representations. Gray Code changes only one bit between consecutive values, while binary may change multiple bits.
Yes. The converter supports Gray Code values of different lengths as long as the input contains valid binary digits.
Scroll to Top