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.
G43 applies the tool length stored in the H offset register to the Z axis, so the program Z0 stays on the face of the part even though every tool sticks out of the holder by a different amount. You program it right after the tool change, in the same block as a safe Z, and cancel it with G49 or H0. Without G43 the machine moves with the previous tool length or with none at all.
For reference only: syntax changes with the control, the post-processor and the machine parameters. Check the official manual and run a simulation before cutting. Legal notice.
The offset takes effect when the Z move in that block runs, which is why it goes next to a safe Z and not in a block of its own. G49 or G43 H0 cancel it. G44 applies the length in the opposite direction and is hardly used today.
Haas (milling)
G43H01Z50.M03S1200
Same as Fanuc. Haas adds the length geometry column and the wear column together. Setting 15 (H & T Code Agreement), when it is on, alarms if the H number does not match the T number.
Siemens 840D / 828D
T3M6D1
Siemens has no G43 and no H: the length comes in with the D edge number of the active tool and goes out with D0. The values live in the tool table, not in a separate offset list.
Heidenhain TNC (Klartext)
TOOLCALL3ZS1200
The L length from the TOOL.T table is applied when the tool is called, with no separate instruction. DL adds a one-off delta correction (DL+0.15) without editing the table.
Address letters used with it
Letter
What it sets
Unit
H
Length offset register number. Shop practice is to use the same number as the tool that has just come in (T4 with H04).
integer (H01, H12...)
Z
Safe height the offset is applied at in that same block. It has to be clearly above the part and above the fixture.
mm / in
H0
Cancels the length offset without writing G49. Handy for leaving a clean state at the end of a subprogram.
no units
Worked example
Second operation of a mill program: the 8 mm drill (T4) comes in to put four holes in. Offset H04 holds the length of that drill referenced to the top face of the part, which is the Z0 of the G54.
G00Z50.M09
( Retracts the previous tool and turns the coolant off. )
G40G80
( Cancels cutter compensation and any canned cycle before the change. )
G91G28Z0.M05
( Z to the reference point in incremental, spindle stopped. The change clears whatever length offset was active. )
T4M06
( Change to the 8 mm drill. )
G90G54G00X20.Y20.
( Absolute, work offset and rapid over the first hole with Z still up. )
G43H04Z25.M03S2400
( Applies the T4 length and comes down to Z25 already compensated. H04 goes with T4: this is the line that prevents most Z crashes. )
M08
( Coolant on. )
G99G81Z-18.R2.F180
( Drills the first hole. With the length applied, Z-18 is a real part dimension and not a distance from the spindle nose. )
X60.
( Second hole: the whole cycle repeats at the new position. )
Y50.
( Third hole. )
X20.
( Fourth hole. )
G80G00Z50.M09
( Cancels the cycle before any rapid move and turns the coolant off. )
G91G28Z0.M05
( Safe retract and spindle stop. )
G49
( Cancels the length offset with the machine already at the reference point, so the control is left in a predictable state. )
Always after a tool change and before the first Z move that goes anywhere near the part. The change clears the previous offset, so the machine is left working with zero length or with whatever the operator left in it at the handle. You program it in the approach block, with a safe Z and usually alongside the spindle start. You also have to write it again if the program goes through a subprogram or an operation that cancelled the offset with G49 or with H0.
How it works with the tool change and with G54
The split is simple: the G54 holds where the face of the part is and the H offset holds how far each tool sticks out. If the shop sets lengths by touching off the part, the G54 Z usually ends up at zero; if lengths are set in a presetter or against the table, the G54 Z carries the part height. What you cannot do is count that height twice, once in the offset and once in the work offset. G43 and G41/G42 are independent: one compensates in Z, the other in the plane.
What it controls and what it does not
G43 only shifts the tool axis, so it corrects depths and heights, never XY dimensions. It is the depth adjustment lever: if a step comes out 0.05 mm deep, you fix the wear column of the offset, not the program. On five-axis machines with rotaries, keeping the tool tip where it belongs while the table or the head swings is a different job and needs the tool center point functions (G43.4 or G43.5 on Fanuc, TCPM on Heidenhain), available only if the machine has them.
Mistakes that cost you a part (or a tool)
Calling an H that is not the tool number (T4 with H03): the machine moves by the length difference between the two tools and you get a short hole or a drill buried in the table.
Forgetting the G43 after the M06: the machine moves with the previous tool length and the program Z0 stops being the face of the part.
Writing G43 H04 in a block with no Z: on many controls the offset does not take effect until the first Z move, and that move is usually the approach to the cut.
Setting tools against the table and also putting the part height in the G54 Z: the same distance is subtracted twice and the tool goes too deep.
Cancelling with G49 and carrying on cutting: with no offset the Z reference becomes the spindle nose at machine zero and the next Z move is close to a guaranteed crash.
Setting the tool in the wear column instead of the geometry column: the later fine adjustment writes over it and nobody can work out where the tenths came from.
Frequently Asked Questions (FAQ)
Does H have to match T?
The control does not require it, but it is the shop rule that causes the fewest accidents: T4 with H04. On Haas you can enforce it with Setting 15 (H & T Code Agreement), which alarms if the numbers do not match. Numbering tools and offsets the same takes one error off the table.
What is the difference between G43 and G44?
G43 applies the length in the usual direction and G44 in the opposite one, meant for tables with the sign inverted. In practice almost every shop works with G43 only; using G44 without knowing how the machine is set takes the tool twice the length in the wrong direction.
Is the offset value positive or negative?
It depends on how you set tools and on the control: some shops store the tool length and others store the distance from machine zero to the face of the part, which comes out negative. What matters is that every tool is measured the same way and that the convention is written down.
Is G43 H0 the same as G49?
In practice yes: both leave the Z axis with no length offset. G49 is more explicit and it is the one that shows up in the safety header blocks; H0 is used when you want to kill the offset without changing the modal state of the group.
Does G43 work in five-axis machining?
For the length offset yes, but it is not enough once the rotary axes swing: there you need tool center point control, which on Fanuc is G43.4 and G43.5 and on Heidenhain is TCPM. They are machine options: if they are not enabled the control alarms.