How to open Gerber files in AutoCAD with free open source tools

Here is a method for how you can import a Gerber RS-274X file into AutoCAD. There are many commercial software solutions to perform this, but this is how you can do it for free using open source tools!

You’ll need to install and configure (if needed) the following software.

  • gerbv – this is used to view Gerber files, and can also export to a variety of formats (but not DXF or DWG for AutoCAD)
  • pstoedit – converts Postscript files to many different other formats
  • ghostscript – needed by pstoedit

Open your Gerber files in gerbv. This process work for multiple layers as well. You should see your Gerber to make sure it is what it should be.

Export the Gerber set to PostScript. File -> Export -> Postscript…

Optionally, if you don’t need to visually check the Gerber file in gerbv, gerbv supports exporting via the command line, for example:

gerbv -x ps MYGERBER.GTL

Now convert the Postscript (.ps) file to DXF using pstoedit. This is best done on the command line.

pstoedit -f dxf foobar.dxf

Now you should have a .dxf file which you can open in AutoCAD.


When working with multiple Gerber files and you export them all at once to one .ps file, and convert them to a single .dxf, all the information comes up in AutoCAD as a single layer, but the original layers can be differentiated by their colours.

However you could manually move different colours to new layers if need be (using QSELECT command in AutoCAD). This probably could be scripted, but that’s a bit beyond my means at the moment.

One thought to “How to open Gerber files in AutoCAD with free open source tools”

  1. Thank you! I was looking for a cleaner way to do this for designing a stencil in DraftSight and you post helped me a lot!
    One note: -f dxf:\”-mm\” will output a DXF with mm units instead of the default, points

Leave a Reply

Your email address will not be published. Required fields are marked *