Converting denary to binary

You can already turn binary into denary. Now go the other way, and see why the two systems match.

Practise this lesson free (6 questions)

More tools

The subtraction method

Write the place values: 128, 64, 32, 16, 8, 4, 2, 1.
Starting from the left, ask: does this place value fit into what is left?
If yes, write 1 and subtract it. If no, write 0.
Carry on until you reach the 1s column.

Example: 45

128? No: 0. 64? No: 0. 32? Yes: 1, leaving 13. 16? No: 0. 8? Yes: 1, leaving 5. 4? Yes: 1, leaving 1. 2? No: 0. 1? Yes: 1.
45 = 00101101
1286432168421
00101101

Check your answer

Always convert back: 32 + 8 + 4 + 1 = 45. Correct.
Use all 8 bits, with 0s at the front if needed.
Odd numbers always end in 1; even numbers always end in 0.
Worked example

Convert 100 to 8-bit binary.

  1. 64 fits: 100 - 64 = 36.
  2. 32 fits: 36 - 32 = 4.
  3. 4 fits: 4 - 4 = 0.
  4. So 1s go under 64, 32 and 4.

Answer: 01100100

Key idea

To convert denary to binary, work from 128 down to 1: write 1 and subtract when the place value fits, otherwise write 0. Check by adding back.

Key words
Denary
The base 10 number system we use every day, with the digits 0 to 9.
Binary
A number system that uses only two digits, 0 and 1. Computers store all data in binary.
AND
A Boolean operator that gives True (1) only when both inputs are True.

All KS3 Computing key terms and definitions →

Quick check

Try two quick questions

See if it has sunk in. Answers are marked straight away.

Extra practice

2 more questions

Try each one, then tap to check.

  1. Convert 12 to 8-bit binary.

    Show the answer

    Answer: 00001100

    12 = 8 + 4, so the bits are 00001100.

  2. Convert 26 to 8-bit binary.

    Show the answer

    Answer: 00011010

    26 = 16 + 8 + 2, so the bits are 00011010.

Check you have got it

Answer 6 quick questions with instant marking. If you get one wrong, GCSE-ready shows you why and gives you another go. It is free, and you do not need an account.

Video for this lesson coming soon. Subscribe on YouTube

Sources and references

Facts checked against the sources below, 27 October 2026. Last updated 2 October 2026. Spotted a mistake? Tell us and we will fix it.

Related lessons