Numbers
Hex Color From Number
Used by developers, writers, and creators worldwide.
This tool turns any number into a hex colour code — the six-digit codes like #1A2B3C that browsers and design tools use. The same number always produces the same colour, so you get a stable, repeatable way to map IDs, seeds, or values onto colours. That makes it handy for colour-coding items by their number, generating consistent avatar or tag colours, or seeding a palette from a known value. The number is run through a hashing step that spreads nearby inputs across very different colours, so 100 and 101 will not look almost identical. Type a number and copy the resulting hex code. It is ideal for developers, designers, and data visualisation, where you want a colour that is determined by data rather than chosen at random each time.
Loading usage…
Free forever — no account required
How to use
- Choose your options above
- Click Generate
- Copy your result
Detailed instructions
- Enter a number to use as the seed.
- Click Generate to get a hex colour.
- Preview the colour swatch.
- Copy the hex code for your use.
Use Cases
- •Colour-coding items by ID
- •Generating avatar or tag colours
- •Seeding a palette from a value
- •Consistent data visualisation
- •Mapping numbers to colours
Tips
- →Same number always gives same colour.
- →Use IDs to colour-code items.
- →Output is ready for CSS.
- →Nearby numbers give distinct colours.
FAQ
does the same number give the same colour
Yes. The conversion is deterministic, so a given number always produces exactly the same hex code. This is what makes it useful for colour-coding data by an identifier that needs to stay consistent over time.
why hash the number first
Without hashing, similar numbers would map to almost identical colours. The hashing step scrambles the bits so that even consecutive numbers produce clearly different, well-spread colours that are easy to tell apart at a glance.
what format is the output
The result is a standard six-digit hex colour code beginning with a hash, such as #3F8AC2. You can paste it straight into CSS, design tools, or anywhere that accepts hex colours.