# 3.7. How to create fax files

Perhaps the easiest way to create fax files is by first creating PostScript file from you document that you wish to fax and then to use the ghostscript PostScript interpreter to transform the PostScript file into one of several fax file, conforming to one of several different fax file format.

In order to create fax files from ps documents you will need ghostscript. KFax can display all fax output modes of ghostscript:

- raw: fag3 faxg32d faxg4

- tiff: tiffg3 tiffg32d tiffg4

A raw file will have no pagination information and will be displayed as a whole in the fax window. Tiff files contain pagination information can be paged through in the fax window.

## 3.7.1. Example

How to create a fax file that sendfax/mgetty can accept and send:

     gs -sDEVICE=faxg3 -sOutputFile=/tmp/fax.g3.%d yourdocument.ps

Assuming that your ps document `yourdocumnet.ps` contains three pages, this will result in the creation of fax.g3.1 fax.g3.2 fax.g3.3