Today, there are many different file formats for all sorts of programs. In 3D printing and CNC machining alone, there are numerous formats for designing, slicing, and machining. DXF, which stands for “data exchange format” or “drawing interchange format”, is one such file format.

Autodesk initially introduced the DXF format for AutoCAD 1.0 in 1982, developing it for compatibility between AutoCAD and other third-party computer-aided design (CAD) programs. The DWG format is the native AutoCAD drawing format, but it’s not compatible with third-party (non-Autodesk) software. The DXF format is capable of providing an exact replica of a DWG drawing and, unlike DWG files, you can also use it in third-party software.

The DXF file format is an open-source, uniquely structured format made by Autodesk for 2D and 3D drawings and models. This format is mainly used to export modeling data between different CAD programs. It can also be useful as a cut file for CNC machining or laser cutting and be processed as a raster or vector file type.

In this article, we’ll go over more about the DXF file and its capabilities. We’ll also see how it compares to similar file formats like STL and DWG. Enjoy!

Back to Contents

What Is a DXF File? - DXF File Format Simply Explained

Features & Limitations

Image of: Features & Limitations
DXF files store a design's geometric information (Source: 3axis Team via 3axis.co)

Since DXF is a file format that’s been around for a while, you might expect it to be rather limited. However, this isn’t exactly the case.

Features

While it does have its limitations, the DXF file format has information-storing capabilities that make it a staple across many different industries. We’ll now take a look at some of this format’s noteworthy features.

Accuracy

Like its close cousin the DWG file, the DXF file type stores vector information, and it’s known for being able to do this fairly accurately. Unlike raster files, the quality of vector files doesn’t reduce when scaled. This ensures a precise outcome for your CNC machining and 3D printing projects.

DXF files are able to store positional data with up to 16-bit floating point accuracy, which means that they have a precision of 0.0000000596046. A DXF file can store points and vertices at these precisions, depending on the file’s unit of measure.

Scaling

Since the units of a DXF file are included with the geometric data, there’s no such thing as scaling issues with this file type. Scaling issues are often a headache when transferring files like STLs, which have no baked-in units – each program using an STL file might have a different default unit. The DXF format skips all of this trouble with a unit variable that is read automatically by any program that can interpret DXF files. If you’re working with the same file across different CAD programs, this can save you a lot of trouble.

Collaboration

The DXF format allows collaborators across different fields to work together on the same design for a project. No matter the different CAD programs used by team members, everyone can work together on the same version of a design. For example, an architect and an engineer using different CAD applications can share their work in one DXF file, which is an extremely useful feature.

Limitations

Image of:
The DXF file format can be used for CNC machining (Source: 3axis Team via 3axis.co)

While there are plenty of positive aspects of DXF files, there are also some limitations to keep in mind about this format. Here are some of the main ones:

3D Printing

At time of writing, few (if any) 3D printing slicers allow for the import of 3D objects as DXF files. To get past this obstacle, DXF files can be converted to STL files, which is a ubiquitous 3D object file type that virtually all 3D printing slicers accept. Note that when converting a DXF file into an STL, you might need to scale the model, as the units used in a DXF model will likely be lost.

DXF files are most effective for communicating 2D data, as these files are often used to export data from 2D CAD programs, such as AutoCAD.

Storage & Transfer

When DXF drawings or other components get complex and large, the file takes up a lot of space. In addition, DXF files store information as plain text, which can slow down the transfer of your design. Luckily, DXF files are often free and widely available. They can also be converted from PDF files, which makes transmitting them easier, as many programs support the PDF format.

Back to Contents

Advertisement
Advertisement
What Is a DXF File? - DXF File Format Simply Explained

How to Open

Image of: How to Open
Using an Autodesk program like AutoCAD is ideal for viewing and editing your DXF files (Source: The CAD Point via YouTube)

Sometimes you’ll need to view DXF models before going through the process of converting them into a format compatible with your 3D modeling program or slicer. There are many programs out there that can interpret DXF files and display them for viewing and editing. To learn more, check out our list of options for viewing DXF files.

For CNC and laser cutting projects, DXF import options typically depend on your specific machine’s workflow. For example, for laser cutting, individual workspaces typically have their own steps for importing DXF files as laser toolpaths. Trotec’s Ruby allows the import of DXF files using its import button. However, some desktop-level machine software, such as Glowforge Print, requires you to convert DXF files to the SVG format.

Engraving tools require a DXF file for the sharp, tooth-shaped tool to follow. Autodesk Fusion’s workflow for engraving requires importing a DXF file as a Fusion sketch and then following a few additional steps. We’ll now take a closer look at how this process works in Fusion as an example.

DXF Files in Fusion

The DXF Import command in Autodesk Fusion
The DXF Import command in Autodesk Fusion (Source: Gabriel Boyd via All3DP)

Many popular 3D CAD programs, such as Siemens’ NX or Dassault Systemes’ SolidWorks, allow DXF files to be imported into designs as sketch objects. Autodesk’s Fusion, a popular example of this type of program, also integrates the DXF file seamlessly into its workflow.

Opening a DXF file in Fusion is similar to importing an SVG file, a McMaster-Carr part, or a mesh object. Here are the steps to follow:

  1. In the “Design” menu, click on the drop-down under the picture of a fastener, labeled “Insert.”
  2. From this drop-down menu, select “Insert DXF.”
  3. Next, select the DXF file being imported from the computer’s file system from the right-hand window.
  4. Select a plane to import the DXF onto and move the DXF into position using the on-screen arrows.
  5. From there, the DXF file will automatically import as a native Fusion sketch object.

This automatic conversion into a Fusion sketch allows it to be edited and applied to the design just like any other sketch object. This makes it incredibly useful for complicated engraving operations, where Fusion’s native sketch-making tools would take a prohibitively long amount of time to create a design that could be done more quickly in other programs, such as Inkscape.

Back to Contents

Advertisement
Advertisement
What Is a DXF File? - DXF File Format Simply Explained

DXF vs. DWG

Some shapes are easy to code manually with DXF's ASCII structure
Some shapes are easy to code manually with DXF's ASCII structure (Source: Manfred Moitzi via ezdxf)

We’ll now take a look at how the DXF format compares to DWG, the previously mentioned vector graphic format also licensed by Autodesk. The DWG format is similar to DXF in that it can also store 2D and 3D drawings and models and they both support vector graphics. They are generally used for the same processes and tasks, although some software will only accept one file type and not the other.

Another important difference is the size of each file. DWG files are typically about 25% smaller in total size. This is primarily because DWG files are composed of binary code, whereas DXF files are composed of ASCII text. Binary code is much smaller than ASCII text (which itself is composed of binary code), meaning that the DWG file saves considerable space in representing the same information in a more compact format.

Lastly, an important distinction is that DXF is open source, while DWG is proprietary and managed by Autodesk. This means that you can only open and edit DWG files with Autodesk software. Since the DXF is open source, its documentation is available freely to the public and you can use it with a variety of different CAD programs.

Back to Contents

Advertisement
Advertisement
What Is a DXF File? - DXF File Format Simply Explained

Converting to Other Formats

A DXF file of a replica Byzantine armor plate open in Inkscape
A DXF file of a replica Byzantine armor plate in Inkscape (Source: Gabriel Boyd via All3DP)

Often, and especially for 3D printing purposes, it’s convenient or even necessary to convert a DXF file to a different file format for use in 3D printing or editing in a particular CAD program. There are many different methods that you can use to convert DXF files into common 3D printing formats. Here’s a look at G-code, STL, and OBJ conversion.

G-code

Since not many CNC machines are equipped to read DXF files and can only read G-code, there may be times when you need to convert to G-code for your CNC projects. Various programs exist to turn DXFs into G-code for several different types of machines, such as ABViewer and dxf2gcode. DXFs can be converted directly to G-code if the DXF file is modeling the movement of an extruder head. These conversion tools allow the end-use of a DXF file to be for manufacturing, meaning that the DXF can turn into G-code for CNC, laser cutters, 3D printers, robotic arms, and more.

STL

The STL file format is one of the most frequently used file formats in 3D designing software today and pretty much all slicers and modeling programs can import or export into STL file format. Since slicers rarely (if ever) accept DXF files as 3D printable objects, it’s useful to convert DXFs to the STL format for 3D printing. Some CAD programs, such as OpenSCAD, SketchUp, and SolidWorks, allow you to open and convert DXF files. There are also free online tools available like Bear File Converter or AnyConv. Unfortunately, any color data or line thickness data will be lost in this process, as the STL file format only saves vertices, lines, and faces.

OBJ

Developed in the late 1980s by Wavefront Technologies for animation software packages, the OBJ format is now one of the most commonly used file types used in 3D software. Since OBJ is more versatile than DXF, has a larger software support base, and can contain information about the color or texture of a model, there are plenty of reasons why your may want to convert from DXF. Free conversion tools will cause the DXF to lose its color when converted over to OBJ, but there are plenty of ways to add these colors and textures back to the OBJ files using online or downloadable tools.

When a DXF file needs to be converted to a less common file format, such as DWG or EPS, it can get a little tricky. Online conversion methods such as CloudConvert seem like an easy solution, but they give users very little control over the conversion process. In addition, sites like these are sometimes unable to successfully convert DXF or DWG files.

To avoid dealing with these sites, even though they may be reliable for other types of conversions (such as EPS to SVG or JPEG to PNG), here are two established methods for converting DXF files into SVG or DWG files using paid and free downloadable software on Windows.

AutoCAD

This info-packed DWG file can be exported as a DXF from AutoCAD
This info-packed DWG file can be exported as a DXF from AutoCAD (Source: FileInfo.com)

AutoCAD, which is one of many CAD tools offered by Autodesk, is the original software that can open and edit DXF (and DWG) files. After installing AutoCAD, which is available on both Windows and Mac, DXF files can be opened rather quickly with the following steps:

  1. Open AutoCAD.
  2. Navigate to and click the “Open” button (folder symbol) in the top left-hand corner, immediately next to the AutoCAD icon. While AutoCAD can be quite slow on certain computers, as long as you have clicked on the button, it should open shortly. If not, close and open all AutoCAD windows and try again.
  3. When the “Select File” menu opens, change the file type option (to the right of “Files of type:”) from “Drawing (*.dwg)” to “DXF (*.dxf)” in the drop-down menu.
  4. Navigate to the file using your computer’s file system, select the file, and select “Open”. The DXF file will now open in a new tab for viewing and editing.
  5. Select “Save As”, which is in the top-left and looks like a floppy disk. When saving, change to the intended file type (such as DWG or SVG) and then click “Save”. Your file should now be successfully converted to the new file type!

Inkscape

Inkscape is a free but still very capable alternative to AutoCAD that can also open DXF files. After downloading Inkscape, opening and editing a DXF file is similar to doing the same in AutoCAD. You can follow these steps:

  1. Open Inkscape.
  2. Select “File > Open…”.
  3. Change the file type to “AutoCAD DXF R13 (*.dxf)”.
  4. Select the intended file from the file system. At this point, the DXF will populate in the Inkscape workspace, where it can be freely viewed and modified.
  5. Select “File > Save As”, then save as the intended file type (which can be chosen from Inkscape’s 20+ available savable file types). At this point, the file will be saved as the new, correct file type.

Back to Contents

Advertisement
Advertisement
What Is a DXF File? - DXF File Format Simply Explained

DXF File Resources

Image of: DXF File Resources
Sites like DXFDownloads offer a large selection of free DXF files (Source: DXFDownloads)

You’ll find that many websites are constantly putting out new DXF files for DIY projects, art installments, and more. Several sites are dedicated to collecting these designs and they’re solid repositories for finding free DXF files by category. Here are a few examples worth checking out:

DXFDownloads

With a rather self-explanatory name, DXFDownloads is a DXF repository where users can find both 2D DXF files and 3D STL files, spanning from DIY CNC furniture to religious reliefs to even a DXF of a steamroller. While the pop-up ads on this site are a bit of a hassle to navigate, the quantity of high-quality files and one-click downloading make it a great place to start looking for DXF files.

3axis.co

The 3axis.co DXF file repository is more focused on the application of laser cutting, and has hundreds, if not thousands, of laser cutting projects and artwork available for free. You can view files by category from the top navigation menu, and you’ll find everything from tools and boxes to decor and puzzles. A great thing about 3axis.co is that search results can be filtered by file type so that only DXF files appear.

CNC Cookbook

CNC Cookbook is a hub of knowledge for various CNC equipment operating tips and techniques, and it also includes a free DXF file repository for testing machines and completing small projects. While it’s not nearly as expansive as the other two options listed above, all of the free DXFs published by CNC Cookbook are first vetted by the team and aren’t simply uploaded by anonymous users. As such, if you need reliable DXF files, this is a great resource. The site even has the option to download all their DXF files in one ZIP file, which is certainly handy for the avid DXF user.

Back to Contents

Advertisement
Advertisement
Advertisement