Null Character

A null character is a special type of character, called a control character, with all its bits set to zero. It is often used in computer programming languages to mark the end of a string. In practical applications, such as database and spreadsheet programs, null characters are used as filler spaces.

In most character encoding sets, such as UTF-8 and ASCII, the null character is the first character in the set. When represented in binary, it appears as all 0s, or 00000000.

A null character in computer source code is often represented by the escape character sequence \0, and is used by programmers to manually set the end of a string. For example, a piece of programming code that stores the text string "Help" will store the following individual characters:

"H" "e" "l" "p" "\0"

The null character, \0, marks the end of the string. Since the null character is a single byte, it is more computationally efficient than using several bytes to set a length when the string is created.

Updated September 30, 2022 by Brian P.

quizTest Your Knowledge

What is a network only accessible by authorized users called?

A
Micronet
0%
B
Macronet
0%
C
Intranet
0%
D
Internet
0%
Correct! Incorrect!     View the Intranet definition.
More Quizzes →

The Tech Terms Computer Dictionary

The definition of Null Character on this page is an original definition written by the TechTerms.com team. If you would like to reference this page or cite this definition, please use the green citation links above.

The goal of TechTerms.com is to explain computer terminology in a way that is easy to understand. We strive for simplicity and accuracy with every definition we publish. If you have feedback about this definition or would like to suggest a new technical term, please contact us.

Sign up for the free TechTerms Newsletter

How often would you like to receive an email?

You can unsubscribe or change your frequency setting at any time using the links available in each email.

Questions? Please contact us.