Text & Code

Text to Binary / Hex / Octal

Convert text to binary, hexadecimal, octal, and decimal — and back.

Separator

Prefix

🔒 All conversions happen in your browser. Nothing is sent anywhere.

☕ Love this tool? Support the developer.

100% free — no ads, no limits. Your support keeps every tool free.

$

Secure payment via Stripe · No account needed

About Text to Binary / Hex / Octal

OptiPix Text Converter transforms text between human-readable characters and their numeric representations in binary, hexadecimal, octal, and decimal (ASCII) formats. Type or paste text and instantly see it in all four formats simultaneously. Reverse the conversion by pasting binary, hex, or octal values to decode back to text. Choose separators (space, none, comma, newline) and prefixes (none, 0b, 0x, 0o) for the output. Full UTF-8 support means it handles emoji and international characters correctly. Copy any format individually. All conversions run locally in your browser.

How It Works

The tool uses JavaScript's TextEncoder to get UTF-8 byte values, then converts each byte to the target base using Number.toString(base). For decoding, it parses the numeric values and reconstructs the original bytes using TextDecoder.

Use Cases

  • Debug character encoding issues in web applications
  • Convert text to binary for educational purposes
  • Generate hex representations for color codes and byte values
  • Inspect raw byte values of Unicode characters
  • Prepare hex-encoded data for network protocols

Frequently Asked Questions

What formats are supported?
Binary (base 2), hexadecimal (base 16), octal (base 8), and decimal ASCII (base 10). All four are generated simultaneously from your input text.
Can I convert binary/hex back to text?
Yes. Switch to decode mode and paste binary, hex, or octal values to convert them back to readable text.
Does it support Unicode and emoji?
Yes. The tool uses UTF-8 encoding, so it correctly handles multi-byte characters including emoji, Chinese, Arabic, and other international scripts.
What separator options are available?
Space (default), no separator, comma, or newline between each byte/character value. You can also add prefixes like 0b (binary), 0x (hex), or 0o (octal).
Is my text sent to any server?
No. All conversions happen in your browser using JavaScript's TextEncoder and number base conversion methods.

Related Tools

All 102 Tools

Image CompressorBackground RemoverVideo CompressorImage UpscalerOCR Text ExtractorFormat ConverterImage ResizerEXIF RemoverFace BlurDepth EstimationQR Code GeneratorWatermark MakerColor Palette ExtractorPhoto FiltersImage to PDFObject DetectionImage ClassifierImage CaptionerAI Image GeneratorMeme GeneratorGIF MakerPhoto Collage MakerImage CropPhoto EffectsImage to SVGColor ChangerNoise RemoverPhoto RestorationColor PickerFavicon GeneratorImage to Base64Image Metadata ViewerImage AnnotatorPassport Photo MakerDocument ScannerASCII Art GeneratorImage ComparisonSprite Sheet GeneratorObject RemoverPanorama MakerWord CounterCase ConverterLorem Ipsum GeneratorUUID GeneratorUnix Timestamp ConverterText DiffURL Encoder / DecoderHTML Entity Encoder / DecoderBase64 Text Encoder / DecoderText to Binary / Hex / OctalHash GeneratorJSON Formatter / ValidatorRandom String GeneratorCSV ↔ JSON ConverterMarkdown EditorUnit ConverterPercentage CalculatorBMI CalculatorAge CalculatorTip CalculatorCSS Gradient GeneratorCSS Box Shadow GeneratorCSS Border Radius GeneratorGlassmorphism GeneratorNeumorphism GeneratorCSS Text Shadow GeneratorFlexbox PlaygroundCSS Grid GeneratorAudio TrimmerAudio ConverterAudio MergerAudio RecorderVideo to Audio ExtractorAudio Speed ChangerAudio Volume BoosterRingtone MakerVocal RemoverText to SpeechSpeech to TextAudio Noise RemoverAudio EqualizerAudio EffectsVideo TrimmerVideo MergerVideo ResizerVideo Speed ChangerVideo RotatorVideo to MP4 ConverterAdd Music to VideoMute VideoVideo LooperReverse VideoVideo ScreenshotAdd Subtitles to VideoVideo WatermarkScreen RecorderWebcam RecorderSlideshow MakerVideo FiltersCron Expression BuilderRegex TesterUnix Timestamp Converter