Please Note: This article is written for users of the following Microsoft Word versions: 2007, 2010, 2013, 2016, 2019, Word in Microsoft 365, and 2021. If you are using an earlier version (Word 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Word, click here: Putting Character Codes to Work.

Putting Character Codes to Work

Written by Allen Wyatt (last updated July 6, 2024)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, Word in Microsoft 365, and 2021


3

If you know the ASCII or ANSI codes for a particular character, and you want to enter it into your document, you can do so by holding down the Alt key and using the numeric keypad. If you enter a three-digit code, then Windows assumes you want the ASCII character associated with that code. If you enter a four-digit code, then Windows assumes you want the ANSI character associated with that code.

For instance, the ASCII code for an uppercase A is 65. You could enter this character by holding down the Alt key and pressing 065 (a three-digit code) on the numeric keypad. It just so happens that this is the same as the ANSI code for an uppercase A, as well. Thus, you could hold down the Alt key and press 0065 (a four-digit code) for the same result. This works because the ASCII and ANSI codes are the same for all values between 0 and 127. When you work with values between 128 and 255, they are different.

You can see this difference by holding down the Alt key and pressing 163 (a three-digit code) on the numeric keypad. This inserts a foreign language character in your document. If you instead use a four-digit code for the same number (hold down the Alt key and press 0163), Word inserts the symbol for the British pound.

You should also know that you can use the Alt key with a regular value. For instance, you can type Alt and then the number 3 on the keypad. This inserts a character for a heart. The values between 0 and 31 do not represent printable characters in either ASCII or ANSI codes. If you hold down the Alt key and enter a number between 1 and 31 on the numeric keypad, Word inserts various miscellaneous dingbat characters in your document. The best way to see how this works is to simply try it in a document of your choosing.

Now for a technical aside: When you press Alt and follow it with a three-digit code, you are inserting characters from what is called the "code page 437," which is the set of characters used in the original IBM PC. When you use a four-digit code, you are inserting characters from what is called "code page 1252" or simply "Windows 1252." Even though I have so far in this tip referred to these as ANSI codes—as is done by many other mere-mortal users of Word—they aren't, technically ANSI codes. There are Microsoft's adaptation of ANSI codes to create what is (again, technically) called "Windows 1252."

More information than you wanted or needed to know? Probably.

Both the "code page 437" (ASCII) and "Windows 1252" (ANSI) code pages are single-byte codes, which is why they go from a value of 0 to 255. However, Unicode characters can use one byte (UTF-8), two bytes (UTF-16), or four bytes (UTF-32), which mean they can use values between 0 and 4,294,967,295. That's obviously a lot of characters, but not all of them are in use.

You can insert Unicode characters, if you know them, by holding down the Alt key and using the numeric keypad. Doing so can be a bit hit-and-miss because it can be difficult to remember such codes. To insert the full range of Unicode characters, you are better off to display the Symbols dialog box. (Display the Insert tab of the ribbon, click Symbol in the Symbols group, and then click More Symbols.) You can then choose a font and a Unicode subset. Word then displays the available characters in the dialog box, and you can select the character you want to insert.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (11219) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, Word in Microsoft 365, and 2021. You can find a version of this tip for the older menu interface of Word here: Putting Character Codes to Work.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Unwanted Lines on Printout

Do you have strange lines appearing at the corners of your printout? There are a number of reasons this could be ...

Discover More

Turning Off Track Changes Change Bars

Word includes a feature that allows you to track changes made to a document. One of the ways in which Word marks your ...

Discover More

Problems Pasting Large Pictures

If you insert a large picture in your document and your text jumps all around and the picture seems to disappear, don't ...

Discover More

The First and Last Word on Word! Bestselling For Dummies author Dan Gookin puts his usual fun and friendly candor back to work to show you how to navigate Word 2013. Spend more time working and less time trying to figure it all out! Check out Word 2013 For Dummies today!

More WordTips (ribbon)

Capitals After Colons

Do you want Word to always capitalize the first letter appearing after a colon? The program won't do it by default, but ...

Discover More

Too Many Edits Prevent Pasting

Sometimes Word can be rather cryptic in the error messages it provides. One such cryptic message warns about "too many ...

Discover More

Capitalizing the First Letter after a Colon

There are many rules in English grammar (and many exceptions to those rules.) One common rule of grammar is to capitalize ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 2 + 2?

2024-07-09 10:40:48

Timothy J. McGowan

@Robert Love: It's not just Word; it's Windows. In Notepad, Alt+1 gives me a smiley face, Alt+3 gives me a heart, et cetera. I'm on Windows 10.

I find in Windows 11, however, Notepad and Word both refuse to acknowledge a number of combinations from Alt+1 through Alt+30, although Alt+11 inserts a line break, Alt+12 inserts a page break, Alt+13 inserts a paragraph break, and Alt+14 inserts a column break. Experimenting has elicited results that I'm unable to replicate just yet; an Alt+Numpad combination followed by a keyboard character will sometimes produce a symbol, but not always. I'd experiment more, but breaktime is over. :)


2024-07-07 04:34:50

Robert Love

For me ALT+numpad with numbers 0 to 31 doesn't work. It just does nothing, i.e. ALT+3 does not insert a heart as described in the tip. I am using Word 2010. Does anyone know which versions of Word it does work with?


2024-07-07 04:11:45

Robert Love

Very useful tip, thanks. For completeness you could mention that at least some of these ALT+numpad sequnces work throughout Windows, not just in Word. I find them especially useful in my Thunderbird email client, whose menu for inserting special characters is frustratingly awkward.

The article doesn't make entirely clear that it is talking only about decimal character codes. Unicode character codes are officially defined in hex, and if you have only the hex code the ALT+decimal technique is no use. This is presumably why Word allows you to insert insert any unicode character by typing its 4-digit hex code in the document and ALT+X immediately after that. For example, 2013 ALT+X produces an endash. I actually find this quicker than ALT+numpad.


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Videos
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.