What Is a DXF File? A CNC Woodworker's Guide

 ·  by  ·  about 8 min read

A DXF (Drawing Exchange Format) is a plain-text file that describes 2D geometry — lines, arcs, circles, polylines — at exact mathematical coordinates, sorted onto named layers. Autodesk created it in the early 1980s so drawings could move between programs, and it stuck. Every CAD and CAM package on the planet reads one.

Here's the part that trips up shops moving to CNC: a DXF is not a machining program. Your router can't run it. A DXF says what the shape is. It says almost nothing about how to cut it — no tool, no depth, no feed rate, no direction. All of that gets added later, and how you set up the DXF determines whether that step takes two minutes or two hours.

What your machine actually eats

The real chain in a cabinet shop looks like this:

Design software → DXF (geometry) → CAM software → G-code / NC (motion) → the machine

The controller only understands the last step: G-code, usually saved as .nc, .tap, or a machine-specific extension. That file is a list of moves — G01 X24.0 Y12.5 F220 and thousands of lines like it. CAM is what turns a shape into moves: it picks the cutter, offsets the path to the correct side of the line, sets depth, and posts it out for your controller.

DXF G-code / NC
Describes Shapes — "what to cut" Motion — "how to cut it"
Knows the tool? No Yes — diameter, speed, depth
Machine-specific? No — universal Yes — tied to your controller
Easy to edit? Yes, in any CAD tool Not really, by hand
Stage Design / handoff Final production

This is why DXF is the standard handoff format between a designer and a cut shop. It's neutral. The shop that owns the machine knows their tooling and their post-processor, so they want the geometry, not somebody else's guess at feeds and speeds.

Layers are the most important thing in the file

If you take one thing away, take this. In a woodworking DXF, the layer name is how manufacturing intent gets encoded. Geometry alone is ambiguous — a circle Ø8 mm could be a through-hole for a connector bolt, a 1/2" (12.5 mm) deep dowel hole, or a shelf pin. The circle looks identical in all three cases. The layer name is the only thing that distinguishes them.

So production shops adopt a naming convention and the CAM tool maps each layer to a tool and a depth. Something like:

Layer Contains Maps to
CUT_THROUGH Part outlines 3/8" compression, full depth + tabs
DRILL_5_D13 Shelf-pin holes Ø5 mm drill, 13 mm deep
DRILL_35_D14 Hinge cups Ø35 mm bit, 14 mm deep
GROOVE_D9 Back panel dado 1/4" straight, 9 mm deep
LABEL Part numbers Engrave shallow, or ignore

Note that the depth lives in the name. It has to — a DXF circle has no Z. This is the single biggest conceptual gap for people coming from drawing software, where a layer is just a way to hide things.

Cabinet hardware is metric even in imperial shops, by the way. Shelf pins are 5 mm, hinge cups are 35 mm, and the 32 mm system spacing came from Europe and never converted. Mixing 3/4" plywood with Ø35 mm boring is completely normal.

The gotcha that ruins a run of doors

Put two different depths on one layer and every hole gets the shallower depth — or the deeper one. Both are bad.

The classic version: a shop lumps all Ø35 mm geometry onto a layer called DRILL_35, with no depth in the name, and the CAM default fires at 10 mm. Hinge cups need roughly 13–14 mm depending on the hinge. Every cup in the batch comes out shallow, the hinge sits proud, and the doors won't close flush. Nothing errors out. The machine did exactly what it was told. You find out at assembly, with a hundred doors already cut.

Put the diameter and the depth in the layer name. Always. It costs nothing and it makes the file self-documenting for whoever runs it six months from now.

Open vs. closed polylines — the silent part-shrinker

For CAM to cut around a shape, it has to know which side is inside. That requires a closed contour. In DXF terms, a polyline carries an explicit closed flag; if that flag isn't set, the software sees an open path even when the ends look perfectly joined on screen.

Two ways this happens:

What happens next depends on the CAM package. Some throw an error, which is the good outcome. Others quietly fall back to cutting on the line instead of outside it. Now the cutter is centered on the boundary and the part loses half the cutter diameter on every edge — with a 1/4" (6.35 mm) bit that's 1/8" (3.2 mm) undersize across the width. On a 30" panel, that gap shows.

Related junk worth cleaning before export: duplicate entities stacked on each other (the machine happily cuts the same line twice), and arcs exploded into hundreds of tiny straight segments, which makes the router stutter. Most CAD tools have an overkill or purge command. Run it.

Units: the 25.4 problem

DXF stores coordinates as bare numbers. The file has a header variable declaring the units — inches, millimeters, or unitless — and a surprising number of exporters write "unitless," which leaves the importing program to guess.

The guess is wrong in one of two directions, and both are obvious once you know the tell:

The habit that prevents it: after every import, measure one dimension you already know. Sheet width, panel height, anything. Two seconds, and it catches the scale error before it reaches the spoilboard. A part that's flatly off by 25.4× is almost never a drawing mistake — it's units, every time.

Why SketchUp and Illustrator exports usually aren't cut-ready

Both export DXF. Neither produces manufacturing data, and this catches people out because the file opens fine.

SketchUp is a 3D modeler, so its DXF export dumps geometry in 3D space — parts at the coordinates where they sit in the assembled cabinet, standing on edge, overlapping. You flatten and lay them out yourself. Curves come out as segmented polylines, faces export as loose edges with no guarantee of closure, and layers follow your modeling tags, which almost never match a machining convention.

Illustrator is worse here, because it's an art tool. Stroke weight is visual and means nothing to CAM — a 2 pt line is not a 2 pt cut. Bézier curves get approximated on export, text stays as text unless you outline it, and artboard scaling means the numbers frequently aren't the numbers you drew.

None of this makes them bad software. They're just solving a different problem. Neither one knows what a shelf pin is, so neither can put it on the right layer at the right depth.

When DXF is the wrong choice

An honest limitation section, because DXF gets recommended reflexively:

DXF's strength and its weakness are the same trait: it's universal because it's dumb. It carries geometry and nothing else. Everything about how to machine it is convention layered on top — which is exactly why the layer naming discipline above matters so much.

Pre-flight checklist

Before a DXF goes to the machine:

  1. Units declared, and one known dimension verified after import.
  2. Every part outline is a single closed polyline.
  3. Layers named with tool diameter and depth — no bare DRILL layer.
  4. No duplicate or stacked entities.
  5. Parts laid flat in 2D, not sitting in 3D assembly positions.
  6. Text either outlined for engraving, or on a layer the CAM skips.

How CabiAI handles this

CabiAI generates the DXF from the cabinet definition rather than from a drawing, which removes most of the failure modes above by construction: outlines come out closed because they're generated as closed contours, holes land on layers named by diameter and depth because the software knows a hinge cup is a hinge cup, and units are declared explicitly. Parts arrive flat and nested onto sheets, not stacked in assembly position. You can export NC directly if your machine takes it.

Which is really the underlying point of this whole article: a cut-ready DXF isn't a drawing you cleaned up. It's a file that was manufacturing data from the start.

Get a cut-ready DXF for your cabinet

Design the cabinet, export DXF or NC with layers, depths, and nesting already handled. Runs in your browser — no CAD required. Free to start.

Try it free