Hex to decimal
Whole numbers from hex to decimal, decimal to binary or between any bases from 2 to 36, exact at any length. Free, with no account or uploads.
Reaches other sites: fetches a JWT key set when you press Fetch · Check it yourself
Convert a number from hex to decimal, or any base
Type numbers, one a line, to see them in decimal. Binary, octal and bases up to 36 are in the step's From and To; long numbers stay exact, and a wrong digit is named with where it is.
Try one
Everything happens in your browser: what you paste or open is never sent anywhere, and nothing is kept when you leave.
A little help along the way
Follow these steps. Every option is explained underneath. Everything happens in your browser; nothing you paste is sent anywhere.
- Paste anythingPaste text into the box at the top. The toolkit says what it may be (Base64, Base64url, Base32, hex, percent-encoding, HTML character references, Unicode escapes, a punycode domain, a data URL, text hiding characters) and why it thinks so. Press a guess to open it with the steps that read it.
- Or build a recipeOpen the toolkit, type or paste your input, or open a file, and add steps from the list on the left (on a phone, Add a step). Each step works on what the one before gave, so URL decode then Base64 decode reads Base64 that was put in an address.
- Set each step's optionsEach step shows its options: the Base64 alphabet and padding, which characters URL encoding keeps, whether HTML references are written by name or number, the escape style for your language. Move a step up or down or remove it.
- Read the notesA step says what it let pass, such as line breaks a Base64 decode passed over or a % that was not followed by two hex digits. When a step cannot go on, it says why and where, and the steps after it wait.
- See the resultThe result shows as text, as a hex dump, as a table of its characters with their code points, names and bytes, as a preview when it is a picture, sound, video or PDF, or as an address taken apart when it is one.
- SwapSwap makes the result the input and turns the recipe around, so Base64 encode becomes Base64 decode: the quickest way to check that something reads back the same.
- Copy, download or shareCopy the result, download it as a file (a picture as a picture), or copy a link to the recipe with its input; the link carries them after the #, which browsers never send to a server.
- Make and read IDsUnder IDs, make UUIDs of any version (4 and 7 are the usual ones), ULIDs, NanoIDs, KSUIDs or ObjectIds, one or up to 100,000, as lines, JSON, CSV or SQL. Paste an ID under Read an ID to see what it holds and, for most kinds, when it was made.
- Hash text and filesUnder Hashes, type text or add files and their hashes are shown; choose the algorithms, the form (hex or Base64), and a key for an HMAC. Paste a checksum or a SHA256SUMS file to check a download. Under Passwords, make and check bcrypt, Argon2 and scrypt hashes.
- Make mock dataUnder Mock data, start from Users, Orders, Nested JSON or Hostile input, or paste a JSON example, a JSON Schema or a CSV header, then change the fields: their kind, options, a share left blank, uniqueness. Choose how many rows, the seed, the language and the file (JSON, CSV, SQL, XML, YAML, TypeScript), and Make: the first rows are shown, and Download has them all.
- Test a regular expressionUnder Regex, choose JavaScript, PCRE2 or Go, type a pattern and a text: matches are marked as you type, each pattern run by its own engine. Replace, Split and List use the matches; What it means explains and draws the pattern; tests must or must not match; and a warning comes before catastrophic backtracking. As code writes it in eight languages.
- Read and make a JWTUnder JWT, paste a token (with or without Bearer): its header, payload and claims are read on this device, times counting down, with warnings for alg none, a missing expiry or a well-known secret. Verify it with a secret, a PEM key or certificate, a JWK or a key set; decrypt an encrypted one; or make and sign a token of your own.
- Read and build a cron scheduleUnder Cron, choose the scheduler (Unix cron, GitHub Actions, Kubernetes, Jenkins, Quartz, Spring, EventBridge or systemd) and type a schedule, or build it field by field: it is said in words, its next runs are listed in any time zone with the days clocks change marked, and it can be written for another scheduler with the file that sets it up.
- KeysAlt or ⌥ + I goes to the input, Alt or ⌥ + A to the steps, Alt or ⌥ + S swaps, Alt or ⌥ + C copies the result, Alt or ⌥ + D downloads it, Alt or ⌥ + L copies a link, Alt or ⌥ + N starts again, Alt or ⌥ + 1 to 7 go to Encode and decode, IDs, Hashes, Mock data, Regex, JWT and Cron, and Ctrl or ⌘ + / lists the keys.
Questions people ask
- How do I convert hex to decimal?
- Type the hex number, with or without 0x, and press Convert to decimal: FF becomes 255. Each hex digit is worth 16 times the one to its right, so FF is 15 × 16 + 15.
- Can it convert decimal to binary, octal or other bases?
- Yes. Choose From and To on the step: binary, octal, decimal, hexadecimal or any base from 2 to 36. Auto reads 0x as hex, 0b as binary and 0o as octal, as Python does.
- Does it work with very long or negative numbers?
- Yes. Numbers are exact at any length, up to 100,000 digits, so a 128-bit hex number gives every decimal digit. A negative number keeps its minus sign; it is not written as two's complement.
- What if I type a wrong digit?
- The page names it and where it is, such as “G” is not a hexadecimal digit at character 4. Spaces, commas and underscores between digits are passed over and said.
This page is the Developer toolkit, opened for this one job; every other tool it has is one press away. Each of its settings is explained on the Developer toolkit's own page.
Read the step-by-step guideKeep going
Guides
- How do I convert hex to decimal, or decimal to binary?
- How do I make a strong passphrase?
- How do I check if my password is strong?
- How do I work out a subnet from CIDR, for IPv4 and IPv6?
- Encode and decode Base64, URL, HTML and Unicode online
- What is Base64, and how do I encode and decode it?
- How to turn a Base64 string into a PDF or image
- What is URL encoding (percent-encoding), and how does it work?