---
title: "Left-Hand Threading M-Code: M04 vs M03 Explained"
description: "A left-hand tap runs on M04, the reverse spindle code, with the G74 cycle on mills. For single-point threading, the spindle and feed direction together set the hand."
url: https://gcodepractice.com/journal/left-hand-threading-m-code-m04-vs-m03/
canonical: https://gcodepractice.com/journal/left-hand-threading-m-code-m04-vs-m03/
author: "Lawrence Arya"
authorUrl: https://www.linkedin.com/in/vibecoding/
published: 2026-06-04
updated: 2026-06-04
category: "Code reference"
tags: ["m04", "m03", "threading", "lathe", "beginner"]
lang: en
---

# Left-Hand Threading M-Code: M04 vs M03 Explained

> **TL;DR** M03 spins the spindle forward (clockwise) and M04 spins it in reverse. A standard right-hand tap cuts under M03 with the G84 tapping cycle; a left-hand tap needs M04 and the G74 reverse tapping cycle. In single-point lathe threading, no single code decides the hand: the combination of spindle direction and feed direction does, and flipping exactly one of them flips the thread from right-hand to left-hand.

Most threads in the world are right-handed, so most programs run the spindle forward on `M03` and nobody thinks about it. The moment a print calls for a left-hand thread, the question gets real: which code flips the hand? The honest answer is that a combination does, and `M04` is the most visible part of it.

## What do M03 and M04 actually control?

`M03` starts the spindle in the forward (clockwise) direction and `M04` starts it in reverse (counterclockwise), as defined in the [LinuxCNC M-code reference](https://linuxcnc.org/docs/html/gcode/m-code.html). Neither code knows anything about threads. They set rotation direction, and thread hand emerges from how that rotation combines with the feed direction and the tool. The basic trio of spindle codes is covered in [M03 vs M04 vs M05](/journal/m03-m04-m05/).

## Which M-code cuts a left-hand tapped hole?

Tapping is the clean case because the tool itself has a hand. A right-hand tap is ground to cut while turning clockwise, so it runs on `M03`. A left-hand tap cuts while turning counterclockwise, so it must run on `M04`. Drive either tap the wrong way and it rubs and snaps instead of cutting, a failure mode the general [threading references](https://en.wikipedia.org/wiki/Threading_(manufacturing)) describe for hand mismatches.

Mill controls bundle the pairing into canned cycles, the same family as the [drilling cycles G81 and G83](/journal/g81-vs-g83-drilling-canned-cycles/):

| Goal | Tap | Spindle code | Tapping cycle |
| --- | --- | --- | --- |
| Right-hand tapped hole | Right-hand tap | `M03` | `G84` |
| Left-hand tapped hole | Left-hand tap | `M04` | `G74` |

`G74` is literally called the reverse tapping cycle: it feeds in with the spindle on `M04`, then flips direction at depth to back the tap out. Calling `G84` with a left-hand tap in the holder is the classic broken-tap setup.

## How does single-point lathe threading decide the hand?

On a lathe with a single-point tool, no single code owns the result. Think of it as a parity rule with three switches: spindle direction, feed direction along Z, and tool orientation. Flip exactly one switch and the hand flips; flip two and they cancel back:

| Spindle | Feed direction | Result |
| --- | --- | --- |
| `M03` forward | Toward the chuck (Z minus) | Right-hand thread |
| `M04` reverse | Toward the chuck (Z minus) | Left-hand thread |
| `M03` forward | Away from the chuck (Z plus) | Left-hand thread |
| `M04` reverse | Away from the chuck (Z plus) | Right-hand thread |

This is why two machinists can both be right when one says left-hand threads need `M04` and the other says he cuts them on `M03`: the first reverses the spindle, the second reverses the feed. The standard [code references](https://www.cnccookbook.com/g-code-m-code-cnc-list-cheat-sheet/) list the codes, but the parity is the part worth understanding.

Beyond taps and single-point passes there is a third threading route, the helical one: how its programs read is covered in [reading a thread milling program](/journal/how-to-read-a-thread-milling-g-code-program/), where arc direction takes over the hand-setting job that spindle direction does here.

## What goes wrong in practice?

The common failures are all mismatches. A left-hand tap driven on `M03` breaks. An `M04` pass with a tool mounted and ground for forward rotation rubs on the wrong face and tears the thread form. A program edited from right-hand to left-hand by changing only the spindle code, while the CAM toolpath still feeds the old direction, cuts the same hand as before and confuses everyone. Change the hand deliberately: decide which one variable you are flipping, and leave the other two alone.

A concrete example: a shop needs a left-hand M10 hole in a fixture plate so the handle does not loosen in use. The setup sheet calls a left-hand tap, the program uses `G74`, and the spindle line reads `S400 M04`. Those three details agree, which is exactly what you check before pressing start.

## Bottom line

`M03` is forward, `M04` is reverse, and neither alone makes a thread left-handed. Left-hand taps run on `M04` with the `G74` cycle; right-hand taps run on `M03` with `G84`. In single-point threading, spindle direction and feed direction together set the hand, and flipping exactly one of them flips the thread. Keeping those pairings instant is what recall practice on the [G-code practice hub](/g-code-practice/) is for, and the wider mill-versus-lathe code differences are mapped in [how to remember lathe M-codes vs mill M-codes](/journal/how-to-remember-lathe-m-codes-vs-mill-m-codes/).

## Sources

- [LinuxCNC M-code reference (M3, M4 spindle control)](https://linuxcnc.org/docs/html/gcode/m-code.html)
- [Wikipedia: Threading (manufacturing)](https://en.wikipedia.org/wiki/Threading_(manufacturing))
- [CNCCookbook: G-code and M-code cheat sheet](https://www.cnccookbook.com/g-code-m-code-cnc-list-cheat-sheet/)

## Frequently asked questions

### Which M-code is used for left-hand threading?
For tapping, `M04` paired with a left-hand tap; on mills the `G74` reverse tapping cycle encodes that pairing, while `G84` is the right-hand cycle on `M03`. For single-point lathe threading, the combination of spindle direction and feed direction sets the hand.

### Can you cut a left-hand thread with M03?
On a lathe, yes: keep `M03` and feed the threading pass away from the chuck instead of toward it. Each single reversal of spindle, feed, or tool orientation flips the hand.

### What happens if you run a left-hand tap with M03?
It rubs instead of cutting, jams, and usually breaks. A left-hand tap is ground to cut counterclockwise, so it must be driven with `M04`.

### What is the best way to memorize spindle and threading codes like M04 vs M03?
Drill them with active recall. A free app like G-Code Sprint quizzes `M03`, `M04`, and the related cycle codes as quick timed questions and repeats whichever ones you miss.

*G-Code Sprint is a study and practice tool only. Always follow your instructor, employer, machine manual, and shop safety procedures.*

---

Source: https://gcodepractice.com/journal/left-hand-threading-m-code-m04-vs-m03/
Author: Lawrence Arya — https://www.linkedin.com/in/vibecoding/
