Designer(s)American Type Founders
Commissioned byAmerican National Standards Institute
Date released1968[1]
VariationsOCR-A Extended

OCR-A is a font created in 1968, in the early days of computer optical character recognition, when there was a need for a font that could be recognized not only by the computers of that day, but also by humans.[2] OCR-A uses simple, thick strokes to form recognizable characters.[3] The font is monospaced (fixed-width), with the printer required to place glyphs 0.254 cm (0.10 inch) apart, and the reader required to accept any spacing between 0.2286 cm (0.09 inch) and 0.4572 cm (0.18 inch).


The OCR-A font was standardized by the American National Standards Institute (ANSI) as ANSI X3.17-1981. X3.4 has since become the INCITS and the OCR-A standard is now called ISO 1073-1:1976. There is also a German standard for OCR-A called DIN 66008.[4]


In 1968, American Type Founders produced OCR-A, one of the first optical character recognition typefaces to meet the criteria set by the U.S. Bureau of Standards. The design is simple so that it can be easily read by a machine, but it is more difficult for the human eye to read.[5]

As metal type gave way to computer-based typesetting, Tor Lillqvist used Metafont to describe the OCR-A font.[when?] That definition was subsequently improved by Richard B. Wales. Their work is available from CTAN.[6]

To make the free version of the font more accessible to users of Microsoft Windows, John Sauter converted the Metafont definitions to TrueType using potrace and FontForge in 2004.[7] In 2007, Gürkan Sengün created a Debian package from this implementation.[8] In 2008. Luc Devroye corrected the vertical positioning in John Sauter's implementation, and fixed the name of lower case z.[9]

Independently, Matthew Skala[10] used mftrace[11] to convert the Metafont definitions to TrueType format in 2006. In 2011 he released a new version created by rewriting the Metafont definitions to work with METATYPE1, generating outlines directly without an intermediate tracing step. On September 27, 2012, he updated his implementation to version 0.2.[12]

In addition to these free implementations of OCR-A, there are also implementations sold by several vendors. As a joke, Tobias Frere-Jones in 1995 created Estupido-Espezial, a redesign with swashes and a long s. It was used in a "technology"-themed section of Rolling Stone.[13][14]


Although optical character recognition technology has advanced to the point where such simple fonts are no longer necessary,[15] the OCR-A font has remained in use. Its usage remains widespread in the encoding of checks around the world. Some lock box companies still insist that the account number and amount owed on a bill return form be printed in OCR-A.[16] Also, because of its unusual look, it is sometimes used in advertising and display graphics.

Notably, it is used for the subtitles in films and television series such as Blacklist and for the main titles in The Pretender. Additionally, OCR-A is used for the films Crimson Tide and 13 Hours: The Secret Soldiers of Benghazi.

Code points

A font is a set of character shapes, or glyphs. For a computer to use a font, each glyph must be assigned a code point in a character set. When OCR-A was being standardized the usual character coding was the American Standard Code for Information Interchange or ASCII. Not all of the glyphs of OCR-A fit into ASCII, and for five of the characters there were alternate glyphs, which might have suggested the need for a second font. However, for convenience and efficiency all of the glyphs were expected to be accessible in a single font using ASCII coding, with the additional characters placed at coding points that would otherwise have been unused.

The modern descendant of ASCII is Unicode, also known as ISO 10646. Unicode contains ASCII and has special provisions for OCR characters, so some implementations of OCR-A have looked to Unicode for guidance on character code assignments.

Pre-Unicode standard representation

The ISO standard ISO 2033:1983, and the corresponding Japanese Industrial Standard JIS X 9010:1984 (originally JIS C 6229-1984), define character encodings for OCR-A, OCR-B and E-13B. For OCR-A, they define a modified 7-bit ASCII set (also known by its ISO-IR number ISO-IR-91) including only uppercase letters, digits, a subset of the punctuation and symbols, and some additional symbols.[17] Codes which are redefined relative to ASCII, as opposed to simply omitted, are listed below:

Character Image Location In ASCII Comments
0x23 # Matches BS 4730, the United Kingdom variant of ISO 646.[18]
0x28 ( Character name is still "LEFT PARENTHESIS", despite showing a brace. Usual left brace ASCII code 0x7B is omitted.[17]
0x29 ) Character name is still "RIGHT PARENTHESIS", despite showing a brace. Usual right brace ASCII code 0x7D is omitted.[17]
0x3C <
0x3E >
0x5C \ Matches JIS X 0201. Included in JIS X 9010, but omitted by ISO 2033.[17]
0x5D ]

Additionally, the long vertical mark (

) is encoded at 0x7C, corresponding to the ASCII vertical bar (|).[17]

Dedicated OCR-A characters in Unicode

Main article: Optical Character Recognition (Unicode block)

The following characters have been defined for control purposes and are now in the "Optical Character Recognition" Unicode range 2440–245F:

Dedicated OCR-A code points based on ASCII and Unicode[19]
Name Image Text Unicode
OCR Hook
OCR Chair
OCR Fork
OCR Inverted fork U+2443
OCR Belt buckle U+2444
OCR Bow tie U+2445

Space, digits, and unaccented letters

OCR-A digits
OCR-A digits
OCR-A unaccented capital letters
OCR-A unaccented capital letters
OCR-A unaccented small letters
OCR-A unaccented small letters

All implementations of OCR-A use U+0020 for space, U+0030 through U+0039 for the decimal digits, U+0041 through U+005A for the unaccented upper case letters, and U+0061 through U+007A for the unaccented lower case letters.

Regular characters

In addition to the digits and unaccented letters, many of the characters of OCR-A have obvious code points in ASCII. Of those that do not, most, including all of OCR-A's accented letters, have obvious code points in Unicode.

Additional OCR-A code points based on ASCII and Unicode
Name Glyph Unicode
Exclamation Mark
Quotation Mark
Number Sign
Dollar Sign
Percent Sign
Left Parenthesis
Right Parenthesis
Plus Sign
Full Stop (Period)
Solidus (Slash)
Less-Than Sign
Equals Sign
Greater-Than Sign
Question Mark
Commercial At
Left Square Bracket
Reverse Solidus (Backslash)
Right Square Bracket
Circumflex Accent
Left Curly Bracket
Right Curly Bracket
Pound Sign (Sterling)
Yen Sign
Latin Capital Letter A with Dieresis
Latin Capital Letter A with Ring Above
Latin Capital Letter AE
Latin Capital Letter N with Tilde
Latin Capital Letter O with Dieresis
Latin Capital Letter O with Stroke
Latin Capital Letter U with Dieresis

Remaining characters

Linotype[20] coded the remaining characters of OCR-A as follows:

Additional OCR-A Characters
Name Glyph Unicode Unicode Name
Long Vertical Mark
U+007C Vertical Line

Additional characters

The fonts that descend from the work of Tor Lillqvist and Richard B. Wales define four characters not in OCR-A to fill out the ASCII character set. These shapes use the same style as the OCR-A character shapes. They are:

Additional ASCII Characters
Name Glyph Unicode
Low Line
Grave Accent
Vertical Line

Linotype also defines additional characters.[21]


Some implementations do not use the above code point assignments for some characters.


The PrecisionID implementation of OCR-A has the following non-standard code points:[22]


The Barcodesoft implementation of OCR-A has the following non-standard code points:[23][24]


The Morovia implementation of OCR-A has the following non-standard code points:[25]


The IDAutomation implementation of OCR-A has the following non-standard code points:[26]

Sellers of font standards

See also


  1. ^ Background on the OCR-A font from Adobe
  2. ^ Motivation for OCR-A from Microscan
  3. ^ "Background on OCR from Embedded Software Engineering". Archived from the original on 2016-09-17. Retrieved 2012-09-01.
  4. ^ DIN 66008-1 Font A For Optical Character Recognition; Characters And Nominal Dimensions
  5. ^ Background on OCR-A from Adobe
  6. ^ The MetaFont sources for OCR-A from CTAN
  7. ^ John Sauter's 2004 OCR-A font from those MetaFont sources
  8. ^ The fonts-ocr-a Debian package, based on John Sauter's SourceForge project
  9. ^ Luc Devroye's account of his changes to John Sauter's implementation of OCR-A
  10. ^ Matthew Skala's home page
  11. ^ The mftrace Debian package
  12. ^ Matthew Skala's 2012 OCR-A font from the MetaFont sources
  13. ^ Hoefler, Jonathan. "Two Fools". Hoefler & Co. Retrieved 18 September 2021.
  14. ^ "Technology, Fall '97". Rolling Stone. No. 774. 1997-11-27. p. 59.
  15. ^ "The History of OCR". Data Processing Magazine. 12: 46. 1970.
  16. ^ Description of a lockbox service, note "The bill contains an invoice and a statement with patient information contained in a scannable Optical Character Recognition (OCR) line. The OCR line is similar in appearance to that found on a credit card statement or telephone bill."
  17. ^ a b c d e ISO/TC97/SC2 (1985-08-01). Japanese OCR-A Graphic Character Set (PDF). ITSCJ/IPSJ. ISO-IR-91.
  18. ^ BSI (1975-12-01). The set of graphic characters of the United Kingdom 7-bit data code (PDF). ITSCJ/IPSJ. ISO-IR-4.
  19. ^ https://www.unicode.org/charts/PDF/U2440.pdf[bare URL PDF]
  20. ^ Linotype's OCR-A font: choose Character Map to see the characters and their coding
  21. ^ Linotype's OCR-A Extended font: choose Character Map then Show all
  22. ^ PrecisionID User Guide for the PrecisionID implementation of the OCR-A font
  23. ^ Information page for the Barcode implementation of the OCR-A font
  24. ^ Another source of information about the Barcode fonts
  25. ^ Information page for the Morovia implementation of the OCR-A font
  26. ^ Information page for the IDAutomation implementation of the OCR-A and OCR-B fonts