Color
- Free forever
- No sign-up
- Instant results
Opacity to HEX Alpha Converter
Convert an opacity percentage to the two hex digits you append to an 8-digit hex colour code. Turn any hex colour transparent without reaching for rgba().
HEX alpha
—
Usage example
—
When would you use this?
You might not know this trick: you can add transparency to any hex colour code by appending a two-character alpha value to the end, turning #6C63FF into #6C63FF80 for 50% opacity, for example. But calculating what percentage maps to which hex value isn't intuitive. This converter takes a percentage from 0 to 100 and gives you the two hex digits to append to any colour code.
Common opacity → HEX alpha values
| Opacity | HEX alpha | 8-digit HEX example |
|---|---|---|
| 1 | FF | #000000FF |
| 0.9 | E6 | #000000E6 |
| 0.8 | CC | #000000CC |
| 0.7 | B3 | #000000B3 |
| 0.6 | 99 | #00000099 |
| 0.5 | 80 | #00000080 |
| 0.4 | 66 | #00000066 |
| 0.3 | 4D | #0000004D |
| 0.2 | 33 | #00000033 |
| 0.1 | 1A | #0000001A |
| 0 | 00 | #00000000 |