Steps per mm Calculator (X, Y, Z)

Work out the steps per mm for a belt-driven X or Y axis, or a lead-screw Z axis, from the hardware: belt pitch and pulley teeth, or screw pitch and number of starts, plus your motor and microstepping. You get the Marlin value (M92), the Klipper rotation_distance and how far the axis moves per step. Converting from Marlin to Klipper? The third tab turns an existing steps/mm into rotation_distance. For the extruder, use the e-steps calculator instead.

These are the values the hardware dictates. Check what your printer currently uses (M503 on Marlin, the [stepper_…] sections of printer.cfg on Klipper) before changing anything, and keep a note of the old value.

The formulas

Klipper's documentation describes each axis by its rotation_distance: how far the axis moves for one full turn of the motor (or of the final gear, if a gear ratio is set) [1]. Marlin uses steps per mm instead [3]. They convert like this:

Worked examples

Belt (Ender-3 style X/Y): 2 mm × 20 teeth = 40 mm per turn. 200 × 16 = 3,200 microsteps per turn, ÷ 40 = 80 steps/mm. Each microstep moves 1 ÷ 80 = 0.0125 mm and each full step 40 ÷ 200 = 0.2 mm. This matches Marlin's Ender-3 example config (80, 80, 400, 93) [4].

Lead screw (T8 Z): 2 mm × 4 starts = 8 mm per turn. 3,200 ÷ 8 = 400 steps/mm, and one full step lifts the Z axis 8 ÷ 200 = 0.04 mm. That 0.04 mm is where the "magic number" layer heights (0.04, 0.08, 0.12, 0.16, 0.2 mm…) come from; see the layer height calculator.

Switching to a 0.9° motor or 32 microsteps doubles the steps per mm (160 for the belt above), because each turn now takes twice as many steps. The rotation_distance stays 40, which is why Klipper keeps it separate from the motor settings.

Gear reduction: a 20-tooth pulley driving the axis through an 80:16 belt reduction (Klipper writes it as gear_ratio: 80:16, driven:drive) is 5:1, so 3,200 × 5 ÷ 40 = 400 steps/mm [1].

Values from real printers

From Klipper's example configs (all 1.8° motors, 16 microsteps) [2]. The last column is the Marlin equivalent by the formula above.

PrinterKlipper configXYZSteps/mm X, Y, Z
Creality Ender-3 (2018)printer-creality-ender3-2018.cfg4040880, 80, 400
Creality Ender-3 V2 (2020)printer-creality-ender3-v2-2020.cfg4040880, 80, 400
Creality Ender-3 S1 (2021)printer-creality-ender3-s1-2021.cfg4040880, 80, 400
Creality CR-10 V3 (2020)printer-creality-cr10-v3-2020.cfg4040880, 80, 400
Anycubic i3 Mega (2017)printer-anycubic-i3-mega-2017.cfg4040880, 80, 400
Prusa MINI+ (2020)printer-prusa-mini-plus-2020.cfg32324100, 100, 800
Voron 2 kit (250 mm)kit-voron2-250mm.cfg4040880, 80, 400

rotation_distance values read from the Klipper repository on 2 Nov 2026. Marlin's Prusa MK3 example config uses 100, 100 and 400 (written 3200/8) steps/mm for X, Y and Z [4]. Your printer's revision may differ, so read your own current values first.

Should you "calibrate" X/Y/Z steps from a test print?

Usually not. Klipper notes that almost all printers should have a whole-number rotation_distance on X, Y and Z [1], because the belt pitch, pulley teeth and screw lead are fixed by the parts. If a calibration cube comes out a fraction of a millimetre off, the usual causes are filament shrinkage, over-extrusion, belt tension or elephant's foot, not the steps. Changing steps to "fix" a cube scales every move and hides the real problem. Check that the hardware numbers above match your parts, then look at flow rate and shrinkage compensation.

A big error (for example parts coming out half or double size) does point to the steps: often a different pulley, a 0.9° motor or a changed microstep setting that the firmware wasn't told about.

Saving the value

Sources

  1. Klipper documentation: Rotation distance. Covers the steps_per_mm formula, 200/400 full steps, 16 microsteps, the whole-number rule, belt pitch × pulley teeth (2 mm × 20 = 40), lead screw pitch × threads (T8 = 8), M6/M8 threaded rods and gear_ratio (80:16).
  2. Klipper example printer configs (the files named in the table).
  3. Marlin: M92, set axis steps-per-unit.
  4. Marlin example configurations, DEFAULT_AXIS_STEPS_PER_UNIT: Creality Ender-3 and Prusa MK3.
  5. Marlin: M500, save settings.

All sources fetched and checked 2 Nov 2026.

Related: stepper driver Vref (A4988, DRV8825, TMC2209 current) · belt tension (GT2 frequency ↔ N) · bed leveling screw turns (M3/M4/M5) · e-steps & extruder rotation distance · layer height & magic numbers · shrinkage compensation · flow rate

FAQ

How do I calculate steps per mm for a belt?

Multiply the belt pitch by the pulley teeth to get the distance per motor turn (2 mm × 20 teeth = 40 mm). Then divide the microsteps per turn by it: 200 full steps × 16 microsteps = 3,200, and 3,200 ÷ 40 = 80 steps/mm.

What are the steps per mm for a T8 lead screw?

A standard T8 lead screw (2 mm pitch, 4 starts) moves 8 mm per turn, so with a 1.8° motor and 16 microsteps it is 3,200 ÷ 8 = 400 steps/mm. A single-start T8×2 screw is 1,600 steps/mm.

What is rotation_distance in Klipper?

It is how far the axis moves in one full turn of the stepper motor, or of the last gear if gear_ratio is set. For a belt it is pitch × pulley teeth (40 for GT2 and 20 teeth); for a lead screw it is pitch × starts (8 for a T8).

How do I convert Marlin steps/mm to Klipper rotation_distance?

rotation_distance = full steps per turn × microsteps ÷ steps per mm. For 80 steps/mm with a 1.8° motor at 16 microsteps that is 200 × 16 ÷ 80 = 40. Klipper says to round to the whole number if the result is within 0.01 of it.

Do I need to change steps per mm if I change microstepping?

In Marlin, yes: steps per mm scales with microsteps, so going from 16 to 32 doubles it (80 to 160 on a GT2 20-tooth axis). In Klipper you change only the microsteps setting; rotation_distance stays the same.

Should I adjust X/Y steps if my calibration cube is off?

Usually not. Belt and lead-screw axes have fixed, whole-number values set by the parts. Small size errors normally come from shrinkage, flow or belt tension, so fix those instead. A large error, like half or double size, points to a wrong pulley, motor or microstep setting.

What are the default steps per mm on an Ender-3?

80 for X and Y, 400 for Z and 93 for the extruder in Marlin's Ender-3 example config. In Klipper that is rotation_distance 40, 40 and 8 for X, Y and Z, with 16 microsteps.