CNC Path Analyzer

The G84 tapping cycle: why F must match spindle speed and pitch, and rigid tapping

Explains with a three-hole M8×1.25 example why the relationship F = S × pitch must always hold in the machining center G84 tapping cycle, the difference between floating and rigid tapping (M29), and how to set tap hole depth and the R point.

Why tapping feed must match the thread pitch

With a drill, spindle speed and feed can be changed fairly freely. A tap, however, has thread-shaped teeth, so it must advance exactly one pitch per revolution. If this relationship is off, the tap strips the thread it has just formed or gets pulled, and in the worst case breaks inside the hole. A broken tap is very hard to remove, and the whole part often has to be scrapped.

That is why the feed in a tapping cycle is not "a reasonable value" but a calculated one. With feed per minute (G94), F = S × pitch; with feed per revolution (G95), F = pitch.

Tap sizePitchF at S500 (G94)F in G95
M6×1.01.0F500F1.0
M8×1.251.25F625F1.25
M10×1.51.5F750F1.5
M12×1.751.75F875F1.75

What G84 does at one hole

  1. Rapid down from the initial point to the R point. The tap must already be turning forward (M03) at the R point.
  2. Feed from the R point to the hole bottom Z at the specified F.
  3. At the bottom, the spindle stops and reverses.
  4. Back out to the R point at the same F: the tap unscrews along the thread in reverse rotation.
  5. The spindle switches back to forward rotation and, with G98, rises to the initial point.

Example path

In the drawing, the short vertical moves that go down and come back up along the same line at each hole are the tap entry and exit. Unlike G83, there is no sawtooth of intermediate retracts, because a tap normally goes to the bottom in one go.

Tapping three holes M8×1.25 at S500, F625

O3001
T6 M6
G21 G90 G17 G94
G54
S500 M03
G00 X10. Y10. Z30.
G43 H6 Z30.
G99 G84 X10. Y10. Z-15. R5. F625
X30.
G98 X50.
G80
G00 Z100.
M30
Tapping three holes M8×1.25 at S500, F625 — XY pathXY
Dashed light blue is G00 rapid traverse; solid orange is cutting motion. Arcs are expanded into calculated static curves.

The figure above is the CNC Path Analyzer result for this program (rapid 8 segments, linear cutting 6 segments).

Floating tapping and rigid tapping

Older machines could not perfectly synchronize spindle rotation and Z feed. They therefore used floating tap holders, with a spring inside that lets the tap move slightly back and forth. The spring absorbs the difference if the feed is a little too fast or too slow. On the other hand, the tap travels further by inertia while the spindle stops and reverses at the bottom, so depth varies considerably.

Most modern machining centers support rigid tapping. The spindle encoder reads the rotation angle and Z moves in exact step with it, so a rigid holder can be used and depth is accurate. On the FANUC family, rigid mode is typically switched on with M29 S_ in the block before G84; depending on the model, a parameter can also make G84 itself run rigid.

ItemFloating tappingRigid tapping
HolderAxial float via a springFixed type (collet, milling chuck)
Synchronization accuracyHolder absorbs the errorController synchronizes by angle
Depth accuracyLow (inertia at the bottom)High
Command exampleG84 ...M29 S500 then G84 ...
High-speed tappingDifficultPossible (depending on the machine)

How to set tap depth and the R point

The first few threads at the tip of a tap are ground to a taper and do not produce full threads. The length of this incomplete section depends on the tap type: there is a big difference between taps for blind holes (1.5–2 threads) and for through holes (around 5 threads). If 12 mm of full thread depth is required with a 2-thread chamfer tap, add 1.25 × 2 = 2.5 mm and command about Z-14.5; the pilot hole must be drilled deeper still so the tap tip does not reach the bottom.

The R point is usually set slightly higher than for drilling. The example's R5. gives the tap room to finish accelerating and enter the hole in a steady synchronized state. Too low and the first thread engages unstably; too high and time spent moving in air increases.

Tapping cycle checklist

  • Pilot hole diameter: Ø6.8 is common for an M8×1.25 coarse thread. If it is smaller, the tap load rises sharply.
  • F calculation: if S was changed, was F changed too? Raising only the spindle speed and leaving F as is, is the most common mistake.
  • Direction of rotation: right-hand threads use G84 with M03, left-hand threads use G74 (the reverse tapping cycle).
  • Bottom clearance: are there at least 1–2 threads left between the tap tip Z and the bottom of the drilled hole?
  • Coolant: tapping is a high-friction process, so whether coolant is supplied (M08) directly affects tap life.

Frequently asked questions

Can G84 do peck tapping with Q?
Some controllers support peck tapping, which goes in and out in sections, when Q is specified in rigid tapping. It is used for deep taps or materials where chips tangle, but it needs model-specific parameter settings, so check the manual.
Is G84 also used on lathes?
Face tapping on a lathe sometimes uses the same G84 number, but the meaning of addresses and the interpretation of R may differ. When moving the same program to a lathe, check the cycle format again.

Next steps

Check the path in CNC Path Analyzer