GCODE → STL

GCODE to STL converter

Lost the original model and only have the .gcode on your printer's SD card or in OctoPrint? This rebuilds the print from the toolpath: every extruded line becomes a thin strand, and the result is saved as an STL.

Drop a GCODE file here or choose one
Files stay on your computer.
Done

How to convert GCODE to STL

  1. Get the GCODE file

    Copy the .gcode from the SD card, OctoPrint's file list, or the slicer's export.

  2. Drop it on the converter

    Drop it above with STL selected.

  3. Open the STL

    Open the STL to inspect it, or slice it again with care.

GCODE to STL: our test

The STL is 34.4 times the size of the GCODE.

Sample file
t.gcode (107 bytes)
STL file
t.stl (4 KB)
Triangles
72
Time in our test
under a second

Tips for converting GCODE to STL

Know what you get. The STL is not the designer's smooth model; it is the print itself, strand by strand, with layer lines, infill and supports included. It shows exactly what the printer would lay down, which is great for inspecting a file but not ideal for re-slicing.

Re-slicing a strand mesh works in principle, but every strand is a separate thin shell and the infill becomes solid geometry. For a reprint, simply send the original G-code to the printer again; it is already sliced for that machine.

Only extruding moves become strands; travel moves are skipped. The layer height is detected from the file, so strands have the right thickness.

Also searched as

“gcode to stl converter”, “gcode to stl file”, “convert gcode to stl”, “convert g code to stl”

Format guides: GCODE files · STL files

Related conversions

Questions

Can I get my original model back from G-code?

Only the printed paths, not the smooth original. Infill and supports are included.

Can I reprint from the STL?

It is easier to reprint the G-code itself.

Are travel moves included?

No, only extrusion.