JPG or PNG to DXF for laser cutting: what works
Published
You have a logo or a drawing as a JPG or PNG and the laser needs a DXF. No converter can turn pixels into exact lines without guessing: the image has to be traced. Done well, it takes a few minutes.
Short answer: a JPG or PNG is a grid of pixels; a DXF is made of lines. To get from one to the other, the image must be traced (vectorised). Trace it in Inkscape, Illustrator or LightBurn, clean the result, then export or convert to DXF. For photos, do not trace: engrave the image directly.
First: does your image need a DXF at all?
| Image | Best route |
|---|---|
| Logo, text, icon, line drawing, silhouette | Trace to vector, then DXF: clean edges you can cut |
| Photo, shading, gradients | Engrave the image directly in LightBurn or xTool (dithering); tracing would lose the shading |
| A logo you already have as SVG, PDF or AI somewhere | Find that file: it is already vector, no tracing needed |
Get a good starting image
- As large as possible: at least 1000 to 2000 pixels across for a logo. Small images give lumpy curves.
- Sharp and high-contrast: black on white is ideal. Remove backgrounds and shadows first if you can.
- PNG rather than JPG: JPG compression adds noise around edges, which becomes small unwanted contours.
Trace it
- Inkscape (free): import the image, select it, Path → Trace Bitmap (Shift+Alt+B). Use Brightness cutoff for a black-and-white logo, adjust the threshold until edges are clean, turn on Suppress speckles and Smooth corners, then delete the original image.
- Illustrator: select the image, Window → Image Trace, preset Black and White Logo, adjust threshold and paths, then Expand.
- LightBurn: Tools → Trace Image traces straight into the laser software, good enough for simple shapes.
Clean before you cut
- Remove specks: tiny shapes from noise. In Inkscape, the trace dialog can suppress small spots; otherwise select and delete them.
- Simplify: a traced curve can have thousands of nodes. A light simplify (Inkscape Path → Simplify, Ctrl+L) makes cutting smoother; too much changes the shape.
- Set the real size: a traced image has no physical size. Scale it to the size you will cut, in millimetres, before exporting.
- Check for holes: letters like o, e, a come out as an outer shape and a hole. If you engrave in xTool, see holes filled when engraving.
Then save the traced result as SVG and convert it here. Our converter does not trace images (it keeps your vector geometry exactly, it does not guess it), but it turns the traced SVG into a clean DXF in millimetres, with one closed polyline per shape and no duplicate lines, plus a laser-ready SVG for xTool.
Convert an SVG to DXFQuestions
Can a JPG be converted directly to DXF?
Only by tracing it: software detects the edges in the pixels and draws lines along them. The result depends on the image quality, so it always needs checking and often some cleaning.
Should I engrave the photo instead of converting it?
For photos and shaded images, yes: laser software engraves images directly, pixel by pixel. Tracing to DXF is for logos, text and line drawings you want to cut or engrave as clean shapes.
Why is my traced DXF full of tiny shapes?
Noise, compression artefacts or shading in the image become hundreds of small contours. Start from a larger, cleaner image, raise the threshold, and remove specks before exporting.
Related problems
- Cricut Christmas SVGs on a laser: what to change first
- Duplicate lines in a DXF: why your laser cuts twice
- Open contours: fill does not work on my DXF
- Laser file imports at the wrong size
- Export a DXF from Illustrator for a laser cutter
- Export a DXF from Inkscape for laser cutting
- Laser-cut Christmas ornaments: check your file before you cut
- The laser cuts through overlapping letters and shapes
- Why the laser engraves the white parts of my design
- Layered snowflakes and stacked holiday designs: cut or engrave?
- Nesting parts in LightBurn Core, without True Nest
- Importing SVG or DXF into LightBurn
- Text missing after converting SVG to DXF
- Holes get filled when engraving a DXF in xTool Studio