We use technical and security cookies and, only if you accept, analytics with no cross-site tracking. More in the Cookie policy and Privacy policy.
We use first-party cookies and technical storage to make the site work, Google reCAPTCHA security technology and, only if you accept, Vercel analytics (no cookies, no cross-site tracking). You can accept or reject analytics; both options are equivalent and you can change your choice at any time. More info: Cookie policy, Privacy policy, Legal notice and Terms and conditions.
Paste your G-code program into the editor or open an example
You'll see the toolpath in 2D and 3D, the cycle time and the safety warnings.
9
1
›
Paste your G-code program here…
ControlMachine
Start with the header
0/6
1Header
2Tooling
3Datums
4Machining
5Retract and end
·Utilities
Pick a template from the list
Fill it in here, see its path in the viewer and insert it below the editor cursor.
Guide
Online G-code simulator and editor: see the toolpath before it reaches the machine
Paste your program or open the file (.nc, .cnc, .gcode, .ngc, .mpf, .txt and Heidenhain .h) and this G-code simulator draws the 2D and 3D toolpath straight away, with playback at real machine speed and the editor line synced to the point on the toolpath. It runs inside the browser, with nothing to install and without uploading the program to any server: the simulation, the warnings and the cycle time are all computed on your own computer. It works for CNC lathe and mill, understands Fanuc, Haas, Siemens, Heidenhain and Fagor cycles, and detects the machine type on its own when you import a program.
1
Simulate G-code and see the toolpath in 2D and 3D
2D and 3D backplot, play button and timeline paced by the cycle time, filtering by tool, cutting-direction arrows, toolpath points and coordinates under the cursor. Click a move in the plot and it jumps to that line of the program; move the cursor in the editor and the matching move lights up. In 3D you can also watch material removal against the stock (experimental) and export the plot as a PNG.
2
CNC lathe G-code simulator: G71, G70, G76 and threading
Lathe cycles are drawn pass by pass, not as a single line: G71, G72 and G73 roughing against the real profile, G70 finishing, G74 and G75 face pecking and grooving, and G76, G92 and G33 threading with every pass and its rapid return. It works in diameter mode, computes the effective rpm under G96 constant surface speed with the G50 or LIMS clamp, and also plots mill-turn programs with live tooling.
3
CNC mill simulator: contours, pockets and G81/G83 drilling
On a mill it plots contours with arcs and helices, G41/G42 cutter compensation and G54 to G59 work offsets, and it expands drilling cycles hole by hole: G81, G82, G83 peck drilling, G73, G84/G74 tapping and G85 to G89 boring. It also draws pocket cycles: Siemens POCKET, Haas G12/G13 and Heidenhain CYCL DEF 251/252.
4
Fanuc, Haas, Siemens Sinumerik, Heidenhain and Fagor
Pick the control (Fanuc, Haas, Siemens, Heidenhain, Fagor, Mitsubishi or plain ISO) or let it detect it, and the editor flags the G/M codes that controller does not accept. It reads the real dialects: Siemens CYCLE95 and MCALL CYCLE8x with R parameters and GOTOF jumps, Heidenhain Klartext (translated to ISO to plot it) and Fagor G68/G69 lathe cycles.
5
Cycle time and crash warnings before the machine
It works out the cycle time by adding up cutting, rapids, tool changes, canned cycles and dwells with the time profile of your machine, and breaks it down by tool and by block. An analyser flags the usual mistakes on the line itself: out-of-range coordinates (a lost decimal point), G01 with no F feed, cutting with no M03/M04 or S, a T with no M06 or a missing M30/M02. It also warns about G00 rapids that run through stock that has not been machined yet, and about overtravel if you set your machine limits.
6
Edit, transform and compare programs
CNC editor with syntax highlighting, find and replace (Ctrl+F), undo and redo, renumbering or stripping N block numbers, and templates. Transform the code without rewriting it: translate, rotate, mirror, scale, change the work offset, repeat in an array, and adjust or clamp F feeds and S speeds. Compare your version with another file, a paste or the original, seeing line by line what changed and how much cycle time you save.
7
Guided programming and AI optimisation
Guided CNC programming helps you write the program with more than 200 lathe and mill templates, with every value explained. With a Pro account, the AI works on the data the simulator has already computed: it reviews the program step by step and answers questions, suggests how to cut the cycle time, compares two versions, hunts for mistakes, summarises and comments the code, and converts it from one control to another (experimental). The AI can make mistakes: always check the result before using it on the machine.
8
How it compares with NC Viewer and other G-code viewers
NC Viewer is a well-known free G-code viewer, handy for a quick look at a toolpath. GetGCode focuses on what happens before the program reaches the machine: it draws each control's lathe and mill cycles pass by pass, works out the cycle time with your machine's profile, warns about rapids through stock, compares program versions and, with Pro, reviews and optimises the program with AI. For a quick look at a simple toolpath, either one will do.
Frequently asked questions
Frequently asked questions about the G-code simulator
Can I simulate G-code online without installing anything?
Yes. Everything runs in the browser: you paste the program or open the file and the toolpath is drawn at once, on a desktop or on a laptop. There is no viewer or desktop CNC editor to install, and the program is not uploaded to any server to be simulated: it is processed on your own computer.
Is there a free online CNC lathe G-code simulator?
Yes, this one. It draws lathe cycles pass by pass (G71, G72 and G73 roughing, G70 finishing, G74 and G75 grooving, and G76 and G92 threading), works in diameter mode, computes the rpm under G96 constant surface speed and estimates the cycle time. It is free, needs no sign-up and runs in the browser.
Can it simulate Fagor 8055, Siemens 840D or Heidenhain TNC programs?
Yes. It reads Fagor in ISO mode with its G68 and G69 lathe cycles; Siemens Sinumerik (840D, 828D) with CYCLE95, MCALL CYCLE8x, POCKET, R parameters and GOTOF jumps; and Heidenhain TNC Klartext (.h), translated to ISO to plot the toolpath, with cycles such as CYCL DEF 200 and 251/252. It is for viewing and checking the program: it does not emulate the control's screen or menus.
Which file formats does it accept?
Files with .nc, .cnc, .gcode, .ngc, .mpf, .txt and .h extensions (Heidenhain Klartext, which is translated to ISO to plot the toolpath). You can also paste the program straight into the editor, with no file at all. It is not a CAD converter: it does not open DXF, DWG or STEP, and it does not turn an image or a drawing into G-code; the G-code generator from a drawing is there for that.
Does it calculate the cycle time?
Yes. It adds up cutting time, rapids at your machine's rapid rate, tool changes, canned cycles and dwells, and breaks the total down by tool and by block. You can tune your machine's time profile so the estimate gets close to what the control shows.
Does it detect crashes or collisions?
It detects one specific and very expensive kind: on a mill, the G00 rapids that run through stock that has not been machined yet, and the moves that go past the machine limits if you have configured them. It is not a full machine collision simulator: it knows nothing about vices, clamps, chuck jaws, tailstock, turret or slides, so a crash into the workholding or into a part of the machine is something it will not see. Keep proving the program out at the machine in single block.
Does it work for Fanuc and Haas?
Yes. Fanuc and Haas are the base dialects, with their lathe and drilling cycles, macros with # variables and M98 subprograms. You can also work in Siemens, Heidenhain, Fagor, Mitsubishi or plain ISO: the editor marks, in the code itself, the G/M codes the selected control does not accept, so the surprise does not wait for you at the machine.
Is it an NC Viewer alternative?
Yes, if you need more than a quick look at the toolpath. NC Viewer is a free viewer for a fast plot; GetGCode adds what you need before the program goes to the shop floor: Fanuc, Haas, Siemens, Heidenhain and Fagor lathe and mill cycles drawn pass by pass, cycle time with your machine's profile, rapid crash warnings, version comparison and, with Pro, AI review and optimisation.
Is it free?
Yes. Simulating, viewing the 2D and 3D toolpath, editing, transforming, inspecting line by line, reviewing the safety warnings, working out the cycle time, comparing programs, using the guided programming templates and exporting are free and with no usage limit. Only the AI features are paid (Pro tier).
Do I need to create an account?
Not for the free part: the simulator and the editor are used without signing up. An account with Pro access is only needed for the AI features. The version history and the settings (machine limits, tool table, time profile) are saved in your browser.
Can I edit the program and download it afterwards?
Yes. You edit on the same screen where you simulate and you download the result as a .cnc file. You can also export a PDF report of the program, a setup sheet, the toolpath as a PNG, or a link that opens the program as it is to pass it to a workmate.
Does it work for lathe and for mill?
For both. When you import a program it detects on its own whether it is lathe or mill (it looks for signs such as G96, T0101, G71 with U/P or G32) and adjusts the view, the XZ plane and the stock; you can also pick the type by hand. On a lathe you get the maximum diameter and the effective rpm under constant surface speed; on a mill, the XYZ envelope and the warning about rapids through stock.