What is a valid HEX color?
A valid HEX color usually starts with # and contains 3, 4, 6 or 8 hexadecimal characters depending on whether shorthand or alpha transparency is used.
Color
Validate HEX color codes online. Check 3, 4, 6 and 8 digit HEX colors, normalize values and preview the result instantly.
Validate HEX color codes online. Check 3, 4, 6 and 8 digit HEX colors, normalize values and preview the result instantly.
This tool runs in your browser. Your input is processed locally and is not uploaded.
Use this free HEX color validator to check whether a HEX color code is valid. Validate short and long HEX values, normalize casing, expand shorthand colors and preview the resulting color instantly.
A valid HEX color usually starts with # and contains 3, 4, 6 or 8 hexadecimal characters depending on whether shorthand or alpha transparency is used.
A 3-digit HEX code is shorthand. For example #fff expands to #ffffff and #000 expands to #000000.
An 8-digit HEX color includes an alpha channel for transparency, such as #ff573380.
Yes, the tool should show a live preview when the entered HEX value is valid.