---
description: G-code is a type of easy-to-use preparatory computer numerical control programming language used in CAM software to control a CNC machine to work automatically.
title: What is G-code for CNC Programming and Machining?
image: https://www.stylecnc.com/uploads/260319/1-260319103223596.jpg
---

# [G-code Definition with All Commands for CNC Machining](https://www.stylecnc.com/user-manual/g-code.html "G-code Definition with All Commands for CNC Machining")

Last Updated: 2026-03-19 By [Jimmy](https://www.stylecnc.com/author/jimmy "Jimmy")3 Min Read

## What is G-code for CNC Programming and Machining?

G-code is a type of easy-to-use preparatory computer numerical control programming language used in CAM software to control a CNC machine to work automatically.

![G-code]()

### What is G code?

G-code is the most common CNC programming language used in CAM (Computer Aided Manufacturing) software to control automatic machine tools, which is also known as RS-274.

G code is the instruction in the CNC program, which is referred to as the G command. Using G code can realize rapid positioning, reverse circular interpolation, parallel circular interpolation, intermediate point circular interpolation, radius programming, and jump processing for CNC machining.

### What is G-code interpreter?

The G code interpreter is an important module of the CNC controller software. [CNC machines](https://www.stylecnc.com/products/ "CNC machines") usually use G codes to describe the machining information of the machine tool, such as the tool path, the selection of coordinates, and the opening of the coolant. It is the main function of the G-code interpreter to interpret G-codes into data blocks that can be recognized by the CNC system. The openness of the G-code interpreter is also a problem that must be considered in the design and implementation.

In the G-code interpreter, keyword decomposition of G-code is the skeleton, and grouping of code is the basis for syntax checking.

The G code interpreter reads the G code, interprets it into G intermediate code, and then undergoes interpolation and position control processing, and finally the output module calls the driver to output it to the PCI or ISA card of a CNC machine.

### What does G code stand for?

G00 stands for quick positioning.

G01 stands for linear interpolation.

G02 stands for clockwise circular interpolation.

G03 stands for counterclockwise circular interpolation.

G04 stands for timed pause.

G05 stands for arc interpolation through intermediate points.

G06 stands for parabolic interpolation.

G07 stands for Z-spline interpolation.

G08 stands for feed acceleration.

G09 stands for feed deceleration.

G10 stands for data setup.

G16 stands for polar programming.

G17 stands for machining XY plane.

G18 stands for machined XZ plane.

G19 stands for machined YZ plane.

G20 stands for imperial sizes (Frank system).

G21 stands for metric sizes (Frank system).

G22 stands for radius size programmatically.

G220 stands for use on system operating interface.

G23 stands for Diameter Size Programmable.

G230 stands for use on the system operating interface.

G24 stands for end of subroutine.

G25 stands for Jump Machining.

G26 stands for loop machining.

G30 stands for magnification write-off.

G31 stands for magnification definition.

G32 stands for Equal Pitch Thread Cutting, Imperial.

G33 stands for Equal Pitch Thread Cutting, Metric.

G34 stands for increased pitch thread cutting.

G35 stands for reduced pitch thread cutting.

G40 stands for tool offset/tool offset logout.

G41 stands for cutter compensation - left.

G42 stands for cutter compensation - right.

G43 stands for tool offset - positive.

G44 stands for tool offset - negative.

G45 stands for tool offset +/-.

G46 stands for tool offset +/-.

G47 stands for tool offset-/-.

G48 stands for tool offset -/+.

G49 stands for tool offset 0/+.

G50 stands for tool offset 0/-.

G51 stands for tool offset +/0.

G52 stands for tool offset-/0.

G53 stands for straight offset, log off.

G54 stands for straight offset X.

G55 stands for straight offset Y.

G56 stands for straight offset Z.

G57 stands for linear offset XY.

G58 stands for straight offset XZ.

G59 stands for straight offset YZ.

G60 stands for accurate path mode (fine).

G61 stands for accurate path mode (middle).

G62 stands for accurate path mode (coarse).

G63 stands for tapping.

G68 stands for tool offset, inside corner.

G69 stands for tool offset, outside corners.

G70 stands for imperial sizes.

G71 stands for metric sizes.

G74 stands for reference point return (machine zero).

G75 stands for returning to the programmed coordinate zero.

G76 stands for threaded compound loops.

G80 stands for canned cycle logout.

G81 stands for external canned cycles.

G331 stands for threaded canned cycles.

G90 stands for absolute size.

G91 stands for relative size.

G92 stands for prefab coordinates.

G93 stands for countdown time, feedrate.

G94 stands for feed rate, feeds per minute.

G95 stands for feed rate, feed per revolution.

G96 stands for constant linear speed control.

G97 stands for cancel constant linear speed control.

### Share This Article With Others

### Further Reading

#### How to Use a CNC Plasma Cutter for Beginners?

2022-09-07[Prev Post](https://www.stylecnc.com/user-manual/how-to-use-cnc-plasma-cutter.html "How to Use a CNC Plasma Cutter for Beginners?")

### Can You Use Regular Router Bits in a CNC Machine?

2022-12-16[Next Post](https://www.stylecnc.com/user-manual/regular-router-bits-in-cnc-machine.html "Can You Use Regular Router Bits in a CNC Machine?")

### Related Guidance

[](https://www.stylecnc.com/user-manual/Woodworking-cnc-router-safety-operation.html "How to Safely Operate a CNC Router Machine for Woodworking?")

2021-04-212 Min Read

#### [How to Safely Operate a CNC Router Machine for Woodworking?](https://www.stylecnc.com/user-manual/Woodworking-cnc-router-safety-operation.html "How to Safely Operate a CNC Router Machine for Woodworking?")

In the use of CNC routers for woodworking, you often encounter some safety problems, you'll understand how to safely operate a wood CNC machine in this manual.

[](https://www.stylecnc.com/blog/cnc-router.html "A Beginner's Guide To CNC Routers")

2025-02-1718 Min Read

#### [A Beginner's Guide To CNC Routers](https://www.stylecnc.com/blog/cnc-router.html "A Beginner's Guide To CNC Routers")

In this article, we will discuss the basic things to consider with CNC routers for beginners, including the definition, parts, bits, tools, accessories, software, CNC programming, setup, installation, operation, caution, safety, types, and everything about CNC router machines.

[](https://www.stylecnc.com/user-manual/How-to-improve-cnc-wood-router-work-efficiency.html "How to Improve Wood CNC Machine Work Efficiency?")

2019-10-292 Min Read

#### [How to Improve Wood CNC Machine Work Efficiency?](https://www.stylecnc.com/user-manual/How-to-improve-cnc-wood-router-work-efficiency.html "How to Improve Wood CNC Machine Work Efficiency?")

Wood CNC machine work efficiency is according to the performance of the cutting material hardness, thickness, tools to determine the right cutting parameters.

[](https://www.stylecnc.com/blog/why-are-industrial-cnc-machines-so-expensive.html "Why Are Industrial CNC Machines So Expensive?")

2024-04-266 Min Read

#### [Why Are Industrial CNC Machines So Expensive?](https://www.stylecnc.com/blog/why-are-industrial-cnc-machines-so-expensive.html "Why Are Industrial CNC Machines So Expensive?")

What makes industrial CNC machines costly? Should I invest so much in them? Read this article to find out why they are so expensive, decide whether to buy one.

[](https://www.stylecnc.com/user-manual/The-functions-of-CNC-router-limit-switch.html "What Are Limit Switches Of CNC Routers Used For?")

2019-08-102 Min Read

#### [What Are Limit Switches Of CNC Routers Used For?](https://www.stylecnc.com/user-manual/The-functions-of-CNC-router-limit-switch.html "What Are Limit Switches Of CNC Routers Used For?")

Limit switch is mounted on CNC router machine or moving objects, when the object approaching the stationary, the limit switch breaking or disconnection.

[](https://www.stylecnc.com/blog/cnc-machining.html "A Beginner's Guide To Pros and Cons of CNC Machining")

2026-03-208 Min Read

#### [A Beginner's Guide To Pros and Cons of CNC Machining](https://www.stylecnc.com/blog/cnc-machining.html "A Beginner's Guide To Pros and Cons of CNC Machining")

CNC machining is a computer-guided manufacturing process, which is used to make precision parts out of various materials ranging from metal to plastic and even wood. This beginner's guide reveals exactly what is CNC machining, how CNC machining works, and its types and processes, as well as the benefits it offers over manual machining and other manufacturing methods. You'll also learn why so many industries from aerospace to healthcare depend on it. While understanding its advantages, we also list its common disadvantages so that you can pay attention to them when purchasing or operating a CNC machine.

### Post A Review

1 to 5-star rating5 stars4 stars3 stars2 stars1 star

#### Share Your Thoughts And Feelings With Others

Review Title

Your Name

Your Email

Your Review

Guest Post

Captcha

![Click To Change Captcha]()

Submit Your Review

### Hotspot Guides

![How Fast And Thick Can Fiber Lasers Cut Through Metal?]()

#### [How Fast And Thick Can Fiber Lasers Cut Through Metal?](https://www.stylecnc.com/blog/fiber-laser-cutting-metal-thickness-speed-power.html "How Fast And Thick Can Fiber Lasers Cut Through Metal?")

2025-02-05

![How to Generate G-Code File with ArtCAM for CNC Machine?]()

#### [How to Generate G-Code File with ArtCAM for CNC Machine?](https://www.stylecnc.com/user-manual/how-to-generate-g-code-file-artcam-cnc-machine.html "How to Generate G-Code File with ArtCAM for CNC Machine?")

2026-03-27

![3 Axis vs 4 Axis vs 5 Axis CNC Router Machine]()

#### [3 Axis vs 4 Axis vs 5 Axis CNC Router Machine](https://www.stylecnc.com/user-manual/3-4-5-axis-cnc-router.html "3 Axis vs 4 Axis vs 5 Axis CNC Router Machine")

2024-01-02

![How to Install and Use NcStudio for CNC Router Machine?]()

#### [How to Install and Use NcStudio for CNC Router Machine?](https://www.stylecnc.com/user-manual/Weihong-Ncstudio-engraver-user-s-operation-manual.html "How to Install and Use NcStudio for CNC Router Machine?")

2024-01-17

![How to Use a CNC Router Machine for Beginners?]()

#### [How to Use a CNC Router Machine for Beginners?](https://www.stylecnc.com/user-manual/cnc-router-machine-user-guide.html "How to Use a CNC Router Machine for Beginners?")

2024-06-26

![A Guide to CNC Programming for Beginners & Programmers]()

#### [A Guide to CNC Programming for Beginners & Programmers](https://www.stylecnc.com/blog/cnc-programming.html "A Guide to CNC Programming for Beginners & Programmers")

2023-08-31

### CNC Machine Catalog

* [CNC Routers](https://www.stylecnc.com/cnc-router/ "CNC Router")
* [CNC Plasma Cutters](https://www.stylecnc.com/plasma-cutter/ "CNC Plasma Cutter")
* [CNC Milling Machines](https://www.stylecnc.com/cnc-milling-machine/ "CNC Milling Machine")
* [CNC Machining Centers](https://www.stylecnc.com/cnc-working-center/ "CNC Machining Center")
* [Edge Banding Machines](https://www.stylecnc.com/edge-banding-machine/ "Edge Banding Machine")
* [CNC Bending Machines](https://www.stylecnc.com/cnc-bending-machine/ "CNC Bending Machine")
* [Laser Cutting Machines](https://www.stylecnc.com/products/laser-cutting-machine.html "Laser Cutting Machine")
* [Laser Marking Machines](https://www.stylecnc.com/laser-marking-machine/ "Laser Marking Machine")
* [Laser Welding Machines](https://www.stylecnc.com/laser-welding-machine/ "Laser Welding Machine")
* [Laser Cleaning Machines](https://www.stylecnc.com/laser-cleaning-machine/ "Laser Cleaning Machine")
* [Laser Engraving Machines](https://www.stylecnc.com/laser-engraving-machine/ "Laser Engraving Machine")
* [CNC Digital Knife Cutters](https://www.stylecnc.com/cnc-knife-cutting-machine/ "CNC Digital Knife Cutting Machine")
* [CNC Wood Lathe Machines](https://www.stylecnc.com/wood-lathe/ "CNC Wood Turning Lathe Machine")
* [CNC Parts, Tools, Accessories](https://www.stylecnc.com/spare-parts/ "CNC Spare Parts, Tools, Accessories")

### Get Easy Solution

Your MachineYour MachineCNC MillCNC LatheCNC RouterLaser CutterLaser WelderLaser CleanerLaser EngraverEdge BanderPanel BenderDigital CutterPlasma CutterWaterjet CutterCNC Machining CenterMultiple ToolsNot Listed Above

Your MaterialYour MaterialMetalWoodFoamGlassPaperStoneFabricPlasticAcrylicCrystalRubberLeatherCompositesMultiple Materials

Your BudgetYour BudgetNo BudgetUnder $3,000$3,000 - $6,000$6,000 - $8,000$8,000 - $10,000$10,000 - $12,000$12,000 - $15,000$15,000 - $20,000$20,000 - $30,000$30,000 - $50,000$50,000 - $80,000$80,000 - $100,000Over $100,000

Your Email

Your Requirements

Submission Successful, Redirecting In 5 Seconds...

### STYLECNC