← AskMachinist · Guides · Calculator · 🔎 Search
Work Offset Basics (G54–G59)
Guide · Updated October 28, 2026
A work offset tells the control where the part datum is in machine coordinates. G54 through G59 each store an X, Y and Z position, so you can run several vises or fixtures from one program.
Trust your tools
Check the edge finder or probe diameter with a mic verified against gage blocks. The free Gage Block Calculator builds the stack.
Step by step
- Pick the datum: Use the datum from the drawing: a corner, a bore center or a fixture pin.
- Home the machine: Reference all axes so machine coordinates are valid.
- Find X and Y: Touch the edges with an edge finder or probe, or indicate a bore center.
- Correct for the tool radius: Add or subtract half the edge finder diameter from the reading.
- Store the values: Enter them in the G54 (or other) offset page, or use the control’s measure function.
- Set Z: Set Z with tool length offsets and a Z datum on the part top or a setter.
- Verify: Jog to X0 Y0 at a safe height and check the position over the part before running.
Worked example
A 0.200 in edge finder approaches the left edge of a part moving +X and kicks at machine X −12.3456. The spindle center is half the diameter short of the edge, so the edge is at −12.3456 + 0.100 = −12.2456. Do the same on the front edge moving +Y: kick at Y −8.1100 gives −8.0100. Enter G54 X −12.2456, Y −8.0100. Jog to G54 X0 Y0 and the spindle should sit right over the corner.
Multiple offsets
Use G54 for vise one and G55 for vise two, or a second operation. The program stays the same; only the called offset changes. Many controls also have extended offsets like G54.1 P1.
Avoiding crashes
Most crashes are a wrong offset called or a sign error. Dry-run above the part, read the distance-to-go, and single-block the first tool.
Tips
- Edges: edge finder basics.
- Z: tool length offsets.
- Radius comp: cutter compensation.
FAQ
What is G54?
The first work offset: the stored machine position of part zero.
How do I set X with an edge finder?
Add or subtract half the edge finder diameter from the kick position.
What is the difference between work and tool offsets?
Work offsets locate the part; tool offsets describe the tool length or radius.
Can I use G55 for a second vise?
Yes; that is the usual way.
How do I check a work offset?
Jog to X0 Y0 at a safe height and confirm the position.
Related guides and calculators
- Edge Finder Basics
- Tool Length Offset Basics
- How to Indicate a Bore True
- How to Indicate a Vise True
- How to Use a Wiggler
- Cutter Compensation Basics (G41/G42)
- How to Use a Tool Presetter
- How to Use a Fixture Plate
- How to Use a CNC Touch Probe
- How to Use a Thread Mill
- Tool Nose Radius Compensation Basics
- CNC G-Code and M-Code Basics
- All free machinist calculators
Build your stack in seconds
The free Gage Block Calculator finds the fewest-block combination for inch and metric sets, with wear blocks. No login.
Questions? Ask a machinist.
General shop information only — follow your machine and tooling manufacturer's instructions and your shop's safety rules.