#GF

#gf icon

METAFONT font

File type: Font and typeface file

A #gf file extension identifies a bitmap font file generated by METAFONT, the font-definition language and program developed by Donald Knuth.

The #gf file stores rasterized glyph data for a particular font and resolution.

What is #gf file?

File type category:
Font and typeface file

Date updated: November 5, 2026

METAFONT, developed by Donald Knuth, is a programming language and interpreter used to define fonts. It processes METAFONT source files and produces bitmap output, including #gf files.

A #gf file contains the bitmap representations of a font's glyphs together with information needed by TeX-related font tools. It is an output or intermediate file, not the METAFONT source itself.

GF files are used in the TeX font workflow. They are commonly converted into more compact bitmap font files for typesetting or used to generate proof output. The generated bitmap fonts can also be used to create fonts for embedding into PostScript. Because the format stores raster glyphs, it is tied to the resolution for which the font was generated.

How to open #gf file?

A #gf file is not normally opened in a text editor or directly edited. Use METAFONT to generate these files from METAFONT source, or use a TeX utility such as GFtoDVI to create proof output from the bitmap font.

How to convert #gf file?

Use GFtoPK, a standard TeX utility, to convert a #gf file to a PK packed bitmap font for use by TeX software. The result remains a raster font at the selected resolution.

For a different resolution or a genuinely different font format, regenerate the font from its METAFONT source rather than converting the existing bitmap file.

Related file extensions