X

String To ASCII Or Hexa Or Binary Converter

This online conversion tool is developed to convert string to ASCII online. Enter the string in the input box below in ASCII converter to convert string to ASCII, hex, and binary number system.

String - ASCII, HEX, Binary

ASCII CODE Chart - Character and their equivalent decimal values

Char NUL SOH STX ETX EOT ENQ ACK BEL BS HT LF VT FF CR SO SI
DEC 00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
Char DLE DC1 DC2 DC3 DC4 NAK SYN ETB CAN EM SUB ESC FS GS RS US
DEC 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Char SP ! " # $ % & ' ( ) * + , - . /
DEC 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
Char 0 1 2 3 4 5 6 7 8 9 : ; < = > ?
DEC 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
Char @ A B C D E F G H I J K L M N O
DEC 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
Char P Q R S T U V W X Y Z [ \ ] ^ _
DEC 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
Char ` a b c d e f g h i j k l m n o
DEC 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
Char p q r s t u v w x y z { | } ~ DEL
DEC 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127

The ASCII calculator converts a given string into:

You only have to enter your string in the ASCII value calculator. It will populate the results in real time. These converted values can be further used for several purposes.

What is a string?

A string can be defined as a sequence of characters either as a literal constant or as some kind of variable. It is used in computer programming as a data type and is implemented as array of bytes.

How to convert string to decimal (ASCII)?

String can be converted to decimal using ASCII table. Follow the steps below to convert string to decimal.

Example:

Convert “hello” to decimal number.

Solution:

Step 1: Pick the equivalent decimal value of each character from the table.

h = 104

e = 101

l = 108

o = 111

Step 2: Arrange all decimal values according to the string.

hello = (104 101 108 108 111)10

How to convert string to Binary?

Want to convert string to binary without using string to ASCII converter?

Let’s convert the string “hello” to binary number.

Step 1: First, we have to convert the string to decimal. We already did that in the previous example. Let’s use the decimal number we got for the string “hello”.

hello = (104 101 108 108 111)10

Step 2: Convert the first decimal number (104) into binary by dividing the decimal number by 2.

104/2

Division
by 2

Quotient

Remainder

104/2

52

0

52/2

26

0

26/2

13

0

13/2

6

1

6/2

3

0

3/2

1

1

Step 3: Write the remainders from bottom to top. The resulting number is a binary number against first decimal number.

104 = (1101000)2

Step 4: Convert all decimals to binary number using the division method above. Here is the binary number for string “hello.”

hello = (01101000 01100101 01101100 01101100 01101111)2

How to convert string to Hexadecimal?

To convert string to hexadecimal, we will first convert the string to decimal.

Step 1: As we have already converted the string “hello” to decimal in the first example, let’s use that decimal number.

hello = (104 101 108 108 111)10

Step 2: Divide the decimal numbers by 16 and write down the quotients and remainders starting from top to bottom.

Division
by 16

Quotient

Remainder

104/16

6

8

101/16

6

5

108/16

6

12 or C

108/16

6

12 or C

111/16

6

15 or F

(104 101 108 108 111)10 = (68 65 6C 6C 6F)16

Note: Some numbers are represented using alphabetic characters in hexadecimal system. Such as, 12 = C.

You can also convert string to int online using this tool.