Processed in your browser

Switching language reloads this page. Copy or save any inputs and results first.

22 / CONVERSION

Number base converter

Convert binary, octal, decimal and hexadecimal precisely.

Preview as you type
5 charsUTF-8 · Up to 200,000 characters
Inputs and results are processed only in this browser and are not saved.
How to use, examples and questions

Convert integers between binary, octal, decimal and hexadecimal. BigInt preserves precision for large and negative integers.

Number base converter — how to use

  1. Choose binary, octal, decimal or hexadecimal as the input base.
  2. Enter an integer in that base. Matching 0b, 0o and 0x prefixes are also accepted.
  3. Review and copy results for each base. Hexadecimal letters appear in uppercase.

Input and output examples

Convert decimal to other bases

Settings: Input base: decimal

Input
255
Output
2進数: 11111111
8進数: 377
10進数: 255
16進数: FF

Frequently asked questions

Can I convert fractions?

Only integers are supported. Decimal points and exponent notation are unavailable. Prefix negative numbers with an ASCII minus sign (-).

Are negative values shown in two's complement?

Negative values use a minus sign followed by their absolute value in each base. Fixed-width two's complement is not calculated. Input limit: 4,096 digits.

Specifications and limits

Fractions are not supported. Accepts 0b / 0o / 0x prefixes for the selected base. Input limit: 4,096 digits.

Analytics and privacy

Conversion inputs and results are processed in your browser. Image URL and OGP loads connect directly to your chosen destination only when you select the corresponding button. Image, video, Markdown, HTML, CSV and TSV files are not uploaded to our servers. Self-signed certificates and signatures are generated locally; private keys are never sent to our servers or analytics. Markdown external images and HTML scripts are not loaded. The API client sends the URL, headers, body and selected files directly to the endpoint only when you select Send or its shortcut. Speed tests exchange generated test data with Cloudflare when you start a measurement. These destinations receive your IP address. We do not proxy these connections or send inputs or measurement results to analytics. Conversions are not saved automatically. Unsaved API inputs, responses, history and environments stay only in this page. Only API requests explicitly selected with Save in this browser are stored. Auth fields, secret variables, known auth headers and files are excluded; review URLs, bodies and custom headers for other secrets first. Collection exports include URLs and bodies, so review them before sharing.

When analytics is enabled, we use Google Analytics 4 to measure pages, tool names and use counts, actions such as copying or saving an image, speed test starts, completion, cancellation and errors, product link clicks, and monitoring guide and service clicks using fixed IDs. Google uses cookies and collects device and browser information. Google signals for advertising and ad personalization are disabled.

Disabling analytics stores only that preference in this browser. Analytics settings never contain your inputs.Google's privacy policy

Analytics is currently unavailable on this site.