I want to insert a null character (ASCII Value 00) into an open file in Notepad. A program that is reading this file is expecting 00 at the end, but it's getting the ASCII value for space - 20.

How can I achieve this?

  • 2
    I had hoped that holding Alt and pressing four zero on the numpad would insert the null the same way it inserts all of the fÜn printable characters but it doesn't.
    – tkryger
    Oct 26, 2009 at 7:06
  • If it did work, you'd only need two zeros, not four. Alt+09 works for Tab, for example.
    – mbomb007
    Mar 13, 2017 at 19:38

3 Answers 3


This is not possible to do with Notepad, however, it can be done with a more advanced editor.

With Notepad++

  1. Go to Edit > Character Panel to show the ASCII Insertion Panel.

  2. Put the cursor where you want to insert the character.

  3. Double-click the character (in the Character column) to insert.

    ASCII Insertion Panel

  • 1
    @DavidPostill It's Notepad++, which is actually what I was searching for when I found this question.
    – mbomb007
    Sep 24, 2016 at 18:06
  • That doesn't help when the OP us using Notepad.
    – DavidPostill
    Sep 24, 2016 at 18:08
  • 5
    @DavidPostill This isn't for the OP anymore. This is for users who find this question when searching. The OP got what he wanted years ago and deleted his account. Besides, this answer is also Notepad++
    – mbomb007
    Sep 24, 2016 at 18:09
  • I found that this does not work if it is the start of a new line; have to type something and then double-click NULL, and then erase the first thing. Just some bug in Notepad++.
    – Abacus
    May 4, 2020 at 15:18
  • 1
    @Abacus It works for me in the most recent version of Notepad++. Make sure you click on the character in the character column, not the Value or Hex. Otherwise, check the encoding of your file.
    – mbomb007
    May 4, 2020 at 16:59

With Notepad++

From HEX

  1. Type 00 00 00
  2. Select this text
  3. TextFX > TextFX Convert > Convert Hex to text

From Base64

  1. Type AA==
  2. Select this text
  3. Plugins > MIME Tools > Base64 Decode

The mapping is:

NUL -> AA=
  • Your steps don't match your mappings. You say AA== in one place and AA= in another.
    – mbomb007
    Sep 23, 2016 at 18:26
  • 1
    Please read the question again carefully. Your answer does not answer the original question. The OP is using Notepad.
    – DavidPostill
    Sep 24, 2016 at 20:06
  • 3
    @DavidPostill The OP asked for something that is impossible, so it's fine that he provide an alternative method of entering a NUL into a file.
    – mbomb007
    Mar 9, 2017 at 14:27

Normal text editors such as Notepad usually do not have the capability to enter NUL characters into files. What you probably want to do is to use a "hex editor" (some text editors also have a "hex" mode). This will let you enter NUL characters, or any other byte you might need.

You must log in to answer this question.