💻 Text to Decimal

📐 工作原理與說明
Encode text into bytes with the selected encoding, take each byte as a 0–255 decimal value, pad to the chosen width, and join with the separator. With the HTML character-reference separator, output Unicode code points (e.g. U+4E2D ⇒ 中) instead of bytes. The per-character view applies the same rule; stats cover characters, bytes (or references) and decimal segments.
把文本轉換為十進位制碼點。
  • 原理:輸出每個字元的 Unicode 碼點的十進位制形式,常用空格或逗號分隔。
  • 範圍:ASCII 字元為 0–127;常用漢字位於 19968–40959 區間。
  • 解碼:按分隔符切分,逐個把數字還原為對應字元。
  • 用途:字元編碼除錯、資料處理與教學。

Convert text to decimal code points and back in your browser — useful for escaping and inspection.

文本 → 十進位制
十進位制 → 文本
批次轉換
With “&# HTML character references”, output uses Unicode code points (U+4E2D ⇒ 中, U+1F600 ⇒ 😀) regardless of UTF-8/UTF-16 bytes; decoding accepts only &#number; references and rejects surrogates or values beyond U+10FFFF.

📊 轉換資訊

-
字元數
-
位元組數
-
十進位制數
-
資料大小

📖 編碼對照表(常用字元)

字元ASCII十六進位制八進位制二進位制

📝 使用說明

文本轉十進位制:將文本字元轉換為十進位制(基數10)ASCII碼錶示。

ASCII 碼:美國資訊交換標準程式碼,使用 0-127 的數字表示字元。

ASCII 模式:每個字元使用 1 位元組,對應 0-255 的十進位制數。

UTF-8 模式:變長編碼,ASCII 字元 1 位元組,中文等字元 3 位元組。

分隔符:可選擇空格、逗號、分號、短橫線、&# HTML實體等格式。

HTML character references: the &# mode outputs Unicode code points, e.g. He (ASCII) or 中 (U+4E2D); decoding accepts only &#number; references, never bytes.

📚 深度解析:文本 / 十進位制 ASCII 碼轉換

💡 常見使用場景

  • 對照 ASCII 十進位制碼錶、做字元編碼練習。
  • 對照 ASCII 碼錶做編碼練習:把字元轉成十進位制碼點,理解大小寫、數字與控制字元的排列規律。
轉換 "AB"
輸入 `AB` → 輸出 `65 66`。

❓ 常見問題(FAQ)

空格的十進位制是多少?
空格 ASCII 為 32。
數字 0 的碼點是多少?
字元 '0' 的 ASCII 碼是 48,'9' 是 57,連續排列;大寫 'A' 是 65、'Z' 是 90;小寫 'a' 是 97、'z' 是 122。這些規律很有用:字元與數值互轉時只需加減固定偏移(如 '7' − 48 = 7)。超過 127 的碼點已不屬於 ASCII。

Formula & Standard References

Item Formula / Note Source / Standard
Code point form output decimal code points, e.g. A = 65 ISO/IEC 10646
Byte form UTF-8 byte values yield several numbers per character RFC 3629
Round-trip code point and byte modes must not be mixed on decode ISO/IEC 10646
⚠️ 使用說明與注意事項