CNC threading cycle generator

Change function

Prepare tapping, lathe threading and helical milling cycles for Fanuc, Haas, Siemens and other controls. Check the template against your machine manual.

Select thread

FiltrosAll

Process parameters

Material

Result ·G84 Rigid Tapping Cycle Fanuc

(M6 x 1 - paso 1 mm)
G21 (unidades en mm)
G90 G54 G00 X0 Y0 Z7 (centrar en agujero · Z segura encima del plano R)
S600 M03
M29 S600 (roscado rígido si aplica)
G84 Z-12 R2 F600 (G84: ciclo roscado derecha (RH) · Z=-12 profundidad abs · R=2 plano R · F=600 mm/min = RPM×paso)
G80 (cancelar ciclo enlatado)

⚠ Indicative base code to review and adapt to your actual post/control. Always verify the code and toolpaths with a qualified professional before machining.

Cycle notes · Recommendations
Cycle notes
›G84: el control sincroniza husillo y Z. F = RPM × paso = 600 × 1 = 600 mm/min. Verifica que F esté en mm/min (G94) o corrige si usas G95.
›Fanuc: M29 activates rigid threading (servo-synchronized spindle). Without M29 = floating thread; requires offset tap holder.
›Confirm unit mode (G20 inch / G21 mm) and R plane before running.
Recomendaciones
✓Through hole: the helical tip tap (gun tap) pushes the chip forward and allows higher speeds without the risk of channel clogging.

Workshop tips and common problems

Technique selection and troubleshooting for the method Tap. Change the threading method above for specific tips.

How to do it right

Tap: spiral flute, spiral point or straight flute

A spiral point (gun tap) pushes chips forward in through holes; a spiral flute evacuates upward in blind holes; straight flutes suit short-chipping materials such as cast iron or brass. Choose the helix angle according to the material's toughness.

Rigid vs. Rigid Threading floating

Rigid tapping (G84/CYCLE84) synchronizes spindle and feed: essential on modern CNC and blind holes. The floating tap holder compensates small sync errors on older machines, but gives less depth control.

Speed and lubrication by material

Carbon steel: 8–15 m/min with cutting oil. Stainless: lower to 4–8 m/min and lubricate abundantly to avoid harshness. Aluminum: 15–30 m/min with polished or TiN core to prevent clogging. Casting: dry or with air.

Useful depth in blind hole

Leave 2–3 pitches of run-out beyond the usable thread: the tap needs room for its lead chamfer and the accumulated chips. Program the hole bottom deeper than the thread so you don't jam the tap.

Go/No-Go gauge inspection

For production valid with Go/No-Go gauge, flank micrometer (3 wires) or plane criterion. The correct drill does NOT guarantee an accepted thread - the tolerance is checked on the flank, not the diameter of the drill bit.

If something goes wrong · symptom → cause → solution

⚠ Tap broken inside the hole

Causes: undersized pilot hole, insufficient lubrication, chips not cleared in a blind hole, misalignment or unsynchronized feed. Fix: open the drill toward the recommended thread %, improve coolant, use rigid tapping and clear chips in deep cycles (peck).

⚠ No-Go Gauge enters (oversized thread)

Causes: worn or oversized tap, excessive float runout, elastic recovery of the material or a tap wrong for the material. Fix: change the tap, reduce tap-holder clearance, lower the speed on springy materials and check the tap class.

⚠ Gauge Go does not fit (tight thread)

Causes: insufficient cutter compensation, insert not reaching depth, burr on the crest or a pilot hole too large with a forming tap. Fix: adjust compensation/depth, deburr the entry and check the forming drill isn't oversized.

⚠ Entrada acampanada (bell-mouth)

The thread ends up wider at the mouth than at the bottom. Causes: tap not perpendicular, unguided start, spindle play or too much float. Fix: start with a guide or feed synchronized from the first thread, check perpendicularity and reduce tool-holder play.

⚠ Poor finish or torn flanks

Causes: high cutting speed in soft/gummy material, worn edge, poor lubrication or a last pass with too much infeed. Fix: lower Vc on aluminum/stainless, change the edge, improve coolant and add a spring pass with almost no depth.

⚠ Incomplete thread at the bottom (blind)

Causes: usable thread programmed to the bottom of the hole with no reserve, or a straight-flute tap that doesn't reach. Fix: drill deeper leaving 2–3 pitches of run-out, use a bottoming tap only for the last threads and check the real usable length.

Other threading tools

Technical guide: CNC threading cycles (G84, G76, G32, CYCLE84)

Reference article for this section. Switch goal above (drill, identify, CNC, method, repair or base plate) to see the guide for that tool.

Every CNC control programs threading with its own syntax, but they all solve the same problem: synchronizing feed and spindle rotation accurately enough not to destroy the thread. This guide reviews the most common cycles and how Fanuc, Haas, Siemens and Heidenhain differ.

Choose the operation and control before generating a cycle. G76 and G84 variants and parameters depend on the control: check the program against your machine manual.

Rigid tapping: G84/G74 and CYCLE84

On Fanuc-type controls, G84 taps right-hand and G74 left-hand; the F feed must be exactly RPM × pitch, and M29 enables rigid tapping (spindle servo-synchronized with the Z axis) before the cycle. Without M29 the cycle is floating and needs a compensating tap holder to absorb the mechanical lag.

Siemens solves the same thing with CYCLE84, which already synchronizes rotation and feed internally by parameters (RTP, RFP, DP, PIT, SDAC): there is no need to program M29 or calculate the feed F by hand.

G76 on lathe: how the cut is distributed between passes

The two-block G76 format separates quality (first block: number of finishing passes, chamfer, profile angle, minimum infeed Q and allowance R) from geometry (second block: final X/Z, P total thread height and Q first pass, both in microns). It automatically splits the total depth into decreasing passes to keep the chip section constant.

The profile angle (P in the first block) must match your insert: 60° for metric/UNC, 55° for Whitworth/BSP, 29°/30° for ACME/trapezoidal. A wrong angle produces flanks that fail the gauge even if the diameter is correct.

Real differences between Fanuc, Haas, Siemens and Heidenhain

Haas NGC supports the same two-block G76 format as Fanuc, more reliable than the single-line K/D format of older versions. Heidenhain uses CYCL DEF 207 (RIGID TAPPING) with parameters Q200/Q201/Q239/Q203/Q204, and needs an explicit call line (L X+0 Y+0 R0 FMAX M99) to run the already defined cycle.

For thread milling by helical interpolation, what really changes between controls isn't the cycle but the sign of the arc's I offset: it must be negative relative to the orbit radius so the arc center sits on the thread axis, whatever the control.

Threading with rotating tool on lathe (C axis)

On lathes with live tooling, the tap turns with M13 (clockwise) or M14 (counterclockwise) instead of M03/M04, and you must position the C axis (G0 C0) before launching the rigid tapping cycle on the hole. It's the usual way to tap radial or face holes without taking the part off the lathe.

Frequently asked questions: CNC threading cycles (G84, G76, G32, CYCLE84)

What G code is used for the tapping cycle in CNC?

In Fanuc and compatible controls, G84 has a right-hand thread and G74 has a left-hand thread. Feed F must match RPM x pitch, and M29 activates rigid threading before cycling if the control supports it.

What is rigid threading and when do I need a floating chuck?

Rigid tapping synchronises the spindle with the Z axis electronically (M29 on Fanuc). If the machine cannot guarantee that synchronisation, you need a floating or compensating tap holder to absorb the mismatch and avoid breaking the tap.

How are the passes distributed in a G76 cycle?

The first G76 block sets the number of spring passes, the chamfer and the profile angle, plus the minimum infeed (Q) and the finishing allowance (R). The second block gives the final geometry (X, Z) and the total thread height (P) together with the first pass (Q), in microns. The control distributes the rest automatically.

How do I program a left-hand thread in CNC?

In tapping cycles, swap G84 for G74 (or the sign of the pitch parameter on Heidenhain/Siemens) and reverse the spindle direction. On a lathe, reverse M03/M04 and confirm the Z feed direction for your control.

What is the difference between CYCLE84 (Siemens) and CYCL DEF 207 (Heidenhain)?

CYCLE84 synchronises rotation and feed internally without needing a separate M29. CYCL DEF 207 only defines the cycle: it needs an explicit call line (L X+0 Y+0 R0 FMAX M99 or CYCL CALL) to run, and on TNC 640 the Q203/Q204 parameters are mandatory.

Third-party trademarks and technical standards are cited for identification and descriptive purposes only; they belong to their respective owners and GetGCode is not affiliated with, authorised or endorsed by them. See the details in the Legal notice.

Related tools