What the G81 Cycle Does
G81 is the simplest drilling canned cycle. It rapids to a safe clearance plane (R), feeds straight to the programmed depth (Z), and retracts—either back to the R-plane (G99) or all the way to the initial plane (G98). Use it for shallow to moderate depth holes where you do not need pecking or a dwell.
Syntax (Fanuc-Style)
G98/G99 G81 X__ Y__ Z__ R__ F__ (modal)
Parameters
-
X, Y – Hole location.
-
Z – Final hole depth (typically negative in metric, e.g., Z-12.5).
-
R – Clearance plane above the part surface where cutting begins (e.g., R2.0).
-
F – Feedrate (mm/min or inch/min).
-
G98 – Retract to initial plane (the Z position before the cycle was called).
-
G99 – Retract to R-plane (faster, common when there are no clamps/obstacles).
Modal behavior: Once issued, G81 stays active. Every subsequent line with a new X/Y repeats the same Z, R, and F until G80 (cancel canned cycle) or another canned cycle is commanded.
Motion Sequence
-
Rapid (G0) to the current X/Y and to R height.
-
Feed (G1) from R down to Z.
-
Retract: G99 returns to R; G98 returns to the initial Z plane.
No dwell & no peck: If you need a dwell at the bottom, use G82. For deep holes or chip control, use G83 (peck drilling).
Example 1: Safe Programming Pattern (Recommended)
Always start a drilling section with a safe line to clear previous modes:
N10 G17 G40 G49 G80 G90 (XY plane, cancel CRC, cancel length comp, cancel cycles, absolute)
Set work and tool data, then call the cycle:

Notes
- G99 used so the tool retracts only to R2. If clamps are high or you need to clear features, swap to G98 before tight areas.
- Z-12.5 includes a small breakthrough for a 12 mm plate—adjust per material/fixture.
Example 2: Using G98 to Clear Clamps

Example 3: Fast Hole Patterns with Incremental XY
A common technique is to keep Z & R from the modal G81, then step X/Y incrementally for patterns. Use G90 to program the cycle (so Z is absolute), then switch XY to incremental with G91.
Tip: While XY are incremental here, Z and R from the modal G81 remain unchanged. Always return to G90 before leaving the section.
Feeds, Speeds & Depth Tips
-
Feedrate (F) for drilling is often set by feed per rev × RPM. Example: 0.10 mm/rev × 1800 rpm = F180 mm/min.
-
R-plane: 2–5 mm above the surface is typical; increase if the part surface isn’t flat.
-
Breakthrough: For through holes, program Z slightly past material thickness (e.g., +0.5 to 1.0 mm) to ensure a clean breakthrough.
-
Coolant: Turn on coolant (M8) before the cycle for better chip evacuation and tool life.
When Not to Use G81
-
Need a bottom dwell → use G82.
-
Need chip breaking or deep-hole strategy → use G83.
-
Need tapping/threading → use G84 (or rigid tapping option if available).
Common Mistakes & How to Avoid Them
-
Forgetting G80: The cycle keeps repeating at each new X/Y—always cancel with G80 when done.
-
R ≤ Z: Ensure R is above the surface and Z is below it; incorrect values can cause alarms or crashes.
-
Wrong plane or offsets: Stay in G17 (XY plane) for drilling on VMCs; verify G54…G59 and H length offsets.
-
Clamps & obstructions: Use G98 in tight areas so the tool retracts high before traversing.
-
Units: Confirm G21/G20 (metric/inch) matches your program and setup sheet.
Quick Checklist Before Running G81 Cycle
-
Tool & Spindle: Correct drill size, spindle direction (M3/M4), RPM, and coolant (M8 if required).
-
Offsets: Right work offset (G54–G59) and tool length offset (G43 H__) active.
-
Cycle Parameters: R-plane above the surface, Z-depth below it, feedrate (F) correct for material.
-
Retract Choice: G98 if clamps/fixtures are in the way, G99 for faster cycles.
-
Safety: Confirm clearance around clamps, fixtures, and part features.
-
Simulation: Run a dry-run or graphics simulation above the part before actual machining.
-
Cancel Cycle: Always end the drilling section with G80 to prevent unintended drilling.