Skip to content
-
Subscribe to our newsletter & never miss our best posts. Subscribe Now!
  • https://www.facebook.com/
  • https://twitter.com/
  • https://t.me/
  • https://www.instagram.com/
  • https://youtube.com/
https://pctechmag.co.uk/ PC Tech Mag

Tech news, gadget reviews, tips, and digital trends — PC Tech Mag keeps you informed on everything technology.

https://pctechmag.co.uk/ PC Tech Mag

Tech news, gadget reviews, tips, and digital trends — PC Tech Mag keeps you informed on everything technology.

  • Home
  • About us
  • Contact us
  • Tech

About This Site

PC Tech Mag is an online tech magazine with PC hardware and gaming guides, Windows tips, software explainers and gadget coverage.

Recent Posts

  • How to Find Duplicates in Google Sheets: 5 Easy Methods
  • How to Add Speaker Notes in PowerPoint: A Step-by-Step Guide
  • Lighter Linux: The Best Lightweight Linux Distros for Old and Slow PCs
  • Ubuntu vs Mint: Which Linux Distro Should You Choose in 2026?
  • How Do I Send a GIF in a Text Message? A Complete Guide for iPhone and Android

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Find Us

Contact: farmanali5starseo@gmail.com

  • Home
  • About us
  • Contact us
  • Tech
Subscribe
Close

Search

what is hexadecimal
Tech

What Is Hexadecimal? Hex Numbers and Digits Explained Simply

By admin
October 30, 2026 7 Min Read
0

You have probably seen hexadecimal without realising it. It hides in web colour codes such as #FF5733, in Wi-Fi settings, in error messages, and in the addresses computers use to find data in memory. It looks strange at first, with letters mixed in with numbers, but once you understand the idea behind it, hexadecimal is simple, logical, and even elegant. This guide explains what is hexadecimal in plain words, how its digits work, and how to convert between hex, decimal and binary.

Number Bases in Plain Words

A number base is simply how many different digits a counting system uses before it has to add another place. The system you use every day is decimal, or base 10. It uses ten digits, 0 to 9. When you reach 9 and add one more, you run out of single digits, so you move to the next place and write 10. That is why 10 does not mean ten separate symbols; it means one ten and zero ones.

Computers, however, do not count in decimal. At their most basic level, they work with switches that are either off or on, which gives us binary, or base 2. Binary uses only two digits, 0 and 1. Counting in binary goes 0, 1, 10, 11, 100, 101, and so on. It is perfect for machines, but very long and hard for people to read. A single byte, for example, is eight binary digits, such as 11111111, and longer values quickly become a wall of ones and zeros.

Hexadecimal, often shortened to hex, sits neatly between these two worlds. It is base 16, which means it uses sixteen digits. Because 16 is a power of two, hex maps very cleanly onto binary: every four binary digits can be written as a single hex digit. That makes hex a compact shorthand for binary, much easier for people to read and write, while still being easy for computers to convert.

The 16 Hex Digits: 0-9 and A-F

Hexadecimal uses the ten familiar digits 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9, and then adds six letters for the values ten to fifteen: A stands for 10, B for 11, C for 12, D for 13, E for 14, and F for 15. After F, the system runs out of single digits, just as decimal runs out after 9, so the next value is written as 10 in hex, which means sixteen in decimal, not ten.

Here is the full conversion table for decimal 0 to 15, with the matching hex digit and the four-digit binary form:

Decimal Hex Binary
0 0 0000
1 1 0001
2 2 0010
3 3 0011
4 4 0100
5 5 0101
6 6 0110
7 7 0111
8 8 1000
9 9 1001
10 A 1010
11 B 1011
12 C 1100
13 D 1101
14 E 1110
15 F 1111

Notice how each hex digit always corresponds to exactly four binary digits. That pattern is the key to the whole system, and it is why programmers and engineers love hex: it lets them write a long binary value in a quarter of the space, without losing any information.

How to Convert Hex to Decimal, Step by Step

Converting hex to decimal is easier than it sounds, because each place in a hex number has a value based on powers of sixteen, just as each place in a decimal number has a value based on powers of ten. In decimal, the places from the right are ones, tens, hundreds, and so on. In hex, the places from the right are ones, sixteens, two hundred and fifty-sixes, and so on, because 16 times 16 is 256.

To convert, work from right to left. Write down each hex digit, turn any letter into its decimal value, multiply it by the value of its place, and then add all the results together. Let us work through a clear example: convert the hex number 2F to decimal.

First, split 2F into its digits: 2 on the left and F on the right. F means 15. The right-hand place is the ones place, so F contributes 15 times 1, which is 15. The left-hand place is the sixteens place, so 2 contributes 2 times 16, which is 32. Add them together: 32 plus 15 equals 47. So, hex 2F equals decimal 47.

Try a slightly longer example: hex 1A3. From the right, 3 is in the ones place, so it contributes 3. A, which means 10, is in the sixteens place, so it contributes 10 times 16, which is 160. The digit 1 is in the two hundred and fifty-sixes place, so it contributes 1 times 256, which is 256. Add them: 256 plus 160 plus 3 equals 419. So, hex 1A3 equals decimal 419. Once you practise with two or three examples, the pattern becomes automatic, and you will start to recognise common values, such as FF meaning 255.

Converting the other way, from decimal to hex, works by repeated division by sixteen. Divide the decimal number by sixteen, note the remainder, and repeat with the quotient until you reach zero. Then read the remainders backwards, turning remainders of ten to fifteen into A to F. For example, decimal 47 divided by sixteen gives a quotient of 2 and a remainder of 15, which is F. The quotient 2 divided by sixteen gives a quotient of 0 and a remainder of 2. Reading backwards gives 2F, which matches our earlier example.

Where Hexadecimal Is Used

Hexadecimal appears in many places where computers need a compact way to show binary data. One of the most familiar is colour codes on the web. Another is memory addresses, the locations where a computer stores data while a program runs. Programmers often write these addresses in hex because they are much shorter than the equivalent binary, and because they line up neatly with how memory is organised.

Hex also appears in MAC addresses, the unique identifiers built into network hardware such as Wi-Fi adapters and Ethernet cards. A MAC address is usually written as six pairs of hex digits separated by colons or hyphens, for example 00:1A:2B:3C:4D:5E. Each pair represents one byte, so the whole address is a compact way to identify a device on a network. Error codes are another common use: when software or hardware reports a fault, it often gives a hex code that a support team can look up precisely, without ambiguity.

Understanding bits and bytes helps here too. A single hex digit represents four bits, and two hex digits represent one byte, which is eight bits. That tidy relationship is a big reason hex is used for data, addresses and colours. If you want a refresher on the units behind data speed and size, our guide to Bits Per Second Explained: Kbps, Mbps and Gbps explains bits, bytes and speed units in plain words.

How to Read a Hex Colour Code

A hex colour code, such as #FF5733, is simply three bytes written in hex, one for each colour channel: red, green and blue. The hash sign at the start tells you the code is in hex. The next two digits are the red value, the following two are the green value, and the last two are the blue value. Each pair can range from 00, which means none of that colour, to FF, which means the maximum amount, or 255 in decimal.

Let us read #FF5733 step by step. FF for red means 255, the maximum red. The green pair is 57 in hex, which is 5 times 16 plus 7, or 87 in decimal, a moderate amount of green. The blue pair is 33 in hex, which is 3 times 16 plus 3, or 51 in decimal, a smaller amount of blue. The result is a strong, warm orange-red, because red dominates, with some green and less blue. By the same logic, #000000 is black, because all three channels are zero, and #FFFFFF is white, because all three are at maximum. Once you know this pattern, you can guess a colour from its code, and you can tweak a website colour by changing one pair at a time.

Hexadecimal may look technical, but at heart it is just another way to count. Decimal is best for everyday maths, binary is best for machines, and hex is the friendly bridge between them. Learn the sixteen digits, remember that each hex digit is four bits, and practise converting a few numbers, and codes that once looked like gibberish will start to make sense.

Frequently Asked Questions

What is hexadecimal in simple words?

Hexadecimal is a base-16 number system that uses the digits 0 to 9 and the letters A to F. It is a short, readable way to write binary numbers used by computers.

Why does hexadecimal use letters?

Because base 16 needs sixteen single digits, and decimal only provides ten. The letters A to F fill the gap, standing for the values 10 to 15, so each value from 0 to 15 can be written with one character.

What is hex FF in decimal?

Hex FF equals 255 in decimal. Each F is worth 15, so the calculation is 15 times 16 plus 15, which is 240 plus 15, or 255.

How do I read a hex colour code?

Read the six digits after the hash as three pairs: the first pair is red, the second is green, and the third is blue. Each pair ranges from 00 for none of that colour to FF for the maximum amount.

Is hexadecimal the same as binary?

No, but they are closely related. Binary uses only 0 and 1, while hexadecimal uses sixteen digits. Each hex digit represents exactly four binary digits, which makes hex a compact shorthand for binary.

Author

admin

Follow Me
Other Articles
Close-up of a central processing unit chip on a motherboard, which a low profile CPU cooler sits on top of
Previous

What Is a Central Processing Unit (CPU)? Parts, Functions, and How It Works

network interface card
Next

Network Interface Card (NIC): What It Is, Types, and How It Works

No Comment! Be the first one.

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

About This Site

PC Tech Mag is an online tech magazine with PC hardware and gaming guides, Windows tips, software explainers and gadget coverage.

Search

Recent Posts

  • How to Find Duplicates in Google Sheets: 5 Easy Methods
  • How to Add Speaker Notes in PowerPoint: A Step-by-Step Guide
  • Lighter Linux: The Best Lightweight Linux Distros for Old and Slow PCs
  • Ubuntu vs Mint: Which Linux Distro Should You Choose in 2026?
  • How Do I Send a GIF in a Text Message? A Complete Guide for iPhone and Android

Find Us

Contact: farmanali5starseo@gmail.com

About This Site

PC Tech Mag is an online tech magazine with PC hardware and gaming guides, Windows tips, software explainers and gadget coverage.

Recent Posts

  • How to Find Duplicates in Google Sheets: 5 Easy Methods
  • How to Add Speaker Notes in PowerPoint: A Step-by-Step Guide
  • Lighter Linux: The Best Lightweight Linux Distros for Old and Slow PCs
  • Ubuntu vs Mint: Which Linux Distro Should You Choose in 2026?
  • How Do I Send a GIF in a Text Message? A Complete Guide for iPhone and Android

Archives

  • December 2026 (15)
  • November 2026 (192)
  • October 2026 (85)

Find Us

Contact: farmanali5starseo@gmail.com

Copyright 2026 — PC Tech Mag. All rights reserved. Blogsy WordPress Theme