Steps per mm calculator for belts, lead screws and a test print

Steps per mm is the motor's full steps per turn times microsteps, divided by how far the axis moves per turn: 80 for a GT2 belt on a 20-tooth pulley and 400 for a T8 lead screw, with a 1.8° motor at 16 microsteps. Pick a belt, a screw or a measured correction to get the M92 line and Klipper's rotation_distance.

Start from
Belt and pulley

Count the teeth on the pulley fixed to the motor shaft. Most printers use a 2 mm pitch GT2 belt.

mm
teeth
Motor and driver

The motor's label gives its step angle. Microsteps are set in the firmware or on the driver.

Driven teeth to motor teeth, as Klipper writes it: 80:16, or 5:1, 80:16 for two stages. Leave blank for a direct drive.

Steps per mm

–

Marlin commands

–

Klipper printer.cfg lines

–

Travel per full step

–

Travel per microstep (theoretical resolution)

–

The formula

steps per mm = full steps per turn × microsteps × gear ratio / travel per turn

belt and pulley:  travel per turn = belt pitch × pulley teeth
lead screw:       travel per turn = thread pitch × thread starts (the lead)
ball screw:       travel per turn = lead
measured move:    new steps per mm = current × commanded / measured

Klipper’s docs give full steps per turn as 360 divided by the step angle: 200 for a 1.8° motor and 400 for a 0.9° motor. Microsteps are a driver setting, and the same docs note that most drivers use 16. The gear ratio is driven teeth over motor teeth, or 1 when the motor turns the pulley or screw directly.

Travel per turn is the number Klipper calls rotation_distance.

How do you calculate steps per mm for a 3D printer?

Multiply the motor’s full steps per turn (200 for a 1.8° motor, 400 for 0.9°) by the driver’s microsteps and any gear ratio, then divide by how far the axis moves in one turn. A 2 mm GT2 belt on a 20-tooth pulley moves 40 mm per turn, so 200 × 16 / 40 = 80 steps/mm.

Worked example: an Ender-3

Creality’s Marlin firmware for the Ender-3 sets DEFAULT_AXIS_STEPS_PER_UNIT { 80.00, 80.00, 400.00, 93.00 }, in the order X, Y, Z, E. Klipper’s Ender 3 config gives the same machine rotation_distance: 40 on X and Y and rotation_distance: 8 on Z, all at 16 microsteps. The formula reproduces both:

  1. Steps per motor turn: 200 × 16 = 3,200.
  2. X and Y: a 2 mm belt on a 20-tooth pulley moves 2 × 20 = 40 mm per turn. 3,200 / 40 = 80 steps/mm.
  3. Z: a T8 lead screw has a 2 mm pitch and 4 starts, so it moves 2 × 4 = 8 mm per turn. 3,200 / 8 = 400 steps/mm.
  4. On Marlin, send M92 X80 Y80 Z400, then M500 to save.

A 0.9° motor or more microsteps

Steps per mm scales with both. For the same 40 mm per turn:

Motor 16 microsteps 32 microsteps
1.8° (200 full steps) 80 160
0.9° (400 full steps) 160 320

The travel per turn does not change, so Klipper’s rotation_distance stays 40 in every cell. Only microsteps and full_steps_per_rotation differ.

With a gear reduction

Multiply by the reduction. The Voron 2.4 config sets each Z motor to rotation_distance: 40, gear_ratio: 80:16 and microsteps: 32: 200 × 32 × (80 / 16) / 40 = 800 steps/mm. Its CoreXY A and B motors have no reduction, so they run 200 × 32 / 40 = 160 steps/mm. Type the reduction as 80:16 in the calculator and it adds the gear_ratio line for Klipper.

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

With a 1.8° motor at 16 microsteps, a 2 mm GT2 belt gives 80 steps/mm on a 20-tooth pulley and 100 on a 16-tooth pulley. A T8 lead screw (2 mm pitch, 4 starts, 8 mm lead) gives 400 steps/mm. Double every value for a 0.9° motor or for 32 microsteps.

All values below are for a 1.8° motor at 16 microsteps (3,200 steps per turn):

Hardware Travel per turn Steps per mm Travel per full step Klipper rotation_distance
GT2 belt, 2 mm, 16-tooth pulley 32 mm 100 0.16 mm 32
GT2 belt, 2 mm, 20-tooth pulley 40 mm 80 0.2 mm 40
MXL belt, 2.032 mm, 20-tooth pulley 40.64 mm 78.74 0.2032 mm 40.64
T2.5 belt, 2.5 mm, 20-tooth pulley 50 mm 64 0.25 mm 50
T8 / TR8x8 lead screw 8 mm 400 0.04 mm 8
TR8x4 lead screw 4 mm 800 0.02 mm 4
TR8x2 lead screw 2 mm 1,600 0.01 mm 2
M8 threaded rod 1.25 mm 2,560 0.00625 mm 1.25
SFU1204 ball screw 4 mm 800 0.02 mm 4
SFU1605 ball screw 5 mm 640 0.025 mm 5

Prusa’s firmware for the i3 MK3S sets X and Y to 100 and Z to 3200/8 = 400, with the XY and Z drivers at 16 microsteps. Those are the 16-tooth and T8 rows, and the Ender-3’s 80 is the 20-tooth one.

Belt pitches come from Gates’ drive design manual: GT2 is 2 mm, MXL is 0.080 in (2.032 mm) and XL is 0.200 in (5.08 mm). T2.5 is 2.5 mm, from the presets in Josef Prusa’s RepRap calculator. To tell GT2 from MXL on a printer, measure 10 teeth of belt: 20 mm is GT2 and 20.32 mm is MXL.

A T8 screw looks like a 2 mm thread but travels 8 mm per turn, because it has 4 separate threads. The Voron Trident config lists the three common 8 mm trapezoidal (TR) screws by their lead: TR8x8 = 8, TR8x4 = 4 and TR8x2 = 2. To check yours, count the thread starts at the end of the screw, or mark the nut and rotate the screw one full turn by hand.

CoreXY steps per mm

A CoreXY printer, where two motors (A and B) work together to move both X and Y, uses the same belt formula for each motor, entered as the X and Y values. Klipper’s config reference describes [stepper_x] as the motor for X+Y movement and [stepper_y] as the motor for X-Y movement, and the Voron 2.4 config gives both rotation_distance: 40.

Marlin’s planner converts a move into X and Y steps with the M92 X and Y values, then drives motor A with their sum and motor B with their difference. So M92 X80 Y80 is right for a CoreXY with 2 mm belts on 20-tooth pulleys at 16 microsteps. Pick “X and Y” in the calculator to get both in one line.

Ball screw steps per mm

A ball screw’s catalog lists its lead, the travel per turn, so there are no starts to count. Phidgets lists the SFU1204 at 12 mm diameter with a 4 mm lead and the SFU1605 at 16 mm with a 5 mm lead. At 3,200 steps per turn that is 800 and 640 steps/mm. For any other size, take the lead from the maker’s table and type it as the pitch with 1 start.

How do you correct steps per mm from a measured print?

Multiply the current value by the commanded distance, then divide by the measured distance: 80 × 100 / 99.6 = 80.32. Klipper’s docs advise against trimming X, Y or Z this way, and a belt axis that prints slightly off rarely has a steps error. Trust a correction only when it points to a wrong setting.

new steps per mm = current × commanded / measured
error            = (measured - commanded) / commanded

Klipper’s warning is blunt: a “measure and trim” method “is not accurate enough for those axes and will likely lead to a worse configuration”. Marlin’s configuration docs link to Triffid Hunter’s Calibration Guide, which says XY steps per mm “can be accurately calculated” from the motor, pulley and belt. Once set, they “shouldn’t need to be calibrated further”. If a correctly calculated axis prints the wrong size by a noticeable amount, the guide says “your belts may be damaged or something else is awry”.

So read the correction as a diagnosis:

Correction (commanded / measured) What it usually means What to do
2 or 0.5 Microsteps off by 2 (16 against 32), or a 0.9° motor set up as 1.8° Fix the microsteps or step angle
4 or 0.25 A lead screw with other starts (TR8x8 against TR8x2), or microsteps off by 4 Check the screw’s lead
1.25 or 0.8 A 20-tooth pulley set up as 16, or a 2.5 mm belt set up as 2 mm Count the pulley teeth
about 1.016 or 0.984 An MXL belt (2.032 mm) set up as GT2 (2 mm) Check the belt pitch
a small error on a belt axis Shrinkage, flow or a worn belt Keep the hardware value
a small error on a lead screw Z The first layer or Z offset Measure above the first layer

The calculator flags the first four and names the setting.

Worked example: a TR8x2 screw on a T8 setting

Say the firmware has the T8 value, 400 steps/mm, but the printer has a TR8x2 screw with a 2 mm lead.

  1. Send G91 (relative moves), then G1 Z10, and measure how far the carriage moved: 2.5 mm.
  2. New value: 400 × 10 / 2.5 = 1,600 steps/mm.
  3. The calculator reports a factor of 4, the gap between an 8 mm lead and a 2 mm one.
  4. 1,600 is exactly the TR8x2 value from the hardware, 3,200 / 2. Set M92 Z1600 and M500, or rotation_distance: 2 on Klipper.

Worked example: a belt axis 0.4% short

These are the calculator’s defaults. X runs at 80 steps/mm, and a 100 mm feature measures 99.6 mm.

  1. New value: 80 × 100 / 99.6 = 80.32 steps/mm.
  2. Error: (99.6 - 100) / 100 = -0.4%.
  3. Klipper equivalent: 3,200 / 80.32 = 39.84, where the belt gives exactly 40.

80 is exact for a 2 mm belt on a 20-tooth pulley, and the 0.4% does not match any setting. Leave the steps alone. A part that shrinks as it cools comes out short in proportion to its size, and too much flow pushes every outer wall out by a fixed amount.

The guide to dimensional accuracy calibration separates those errors, and the shrinkage calculator turns the measurement into a per-filament scale in the slicer. If X and Y each measure right but a printed square comes out as a parallelogram, the axes are not square to each other, which the skew calculator handles.

Z on a lead screw

The lead is cut into the screw, so the value from the hardware is normally exact. A Z height that measures off can come from the first layer, since the Z offset sets its thickness. Measure a height that starts above the first layer, and only trust a correction that matches a setting in the table above.

If you measure anyway

  1. Take out backlash, the play between motor and carriage, first. Triffid Hunter’s guide warns that parts printed with lash are not usable as calibration pieces. On a belt axis, check tension with the belt tension calculator.
  2. Measure the longest distance you can. Ellis’ Print Tuning Guide advises basing dimensional adjustments on larger objects, where small errors are proportionally smaller.
  3. Measure the axis’s own move where you can, with calipers or a dial indicator on the carriage, so wall width and shrinkage stay out of the number.
  4. Enter the current value, the commanded distance and the measured one. A factor in the table means a setting to fix. Anything else on a belt axis goes to the slicer.

The calibration formulas guide puts this correction next to the extruder and flow ones.

Setting steps per mm in Marlin, Klipper and RepRapFirmware

Marlin. M92 X80 Y80 Z400 sets the running values. Marlin’s docs say M92 with no parameters reports them (M503 on older versions), and with EEPROM_SETTINGS enabled M500 saves them and M501 loads them. M502 resets every axis to the firmware’s DEFAULT_AXIS_STEPS_PER_UNIT line in Configuration.h.

Klipper. Klipper has no M92 among its supported G-codes. It takes the travel per turn as rotation_distance in each [stepper_x], [stepper_y] and [stepper_z] section. The same section sets microsteps, plus full_steps_per_rotation: 400 for a 0.9° motor (200 is the default). Send RESTART after editing printer.cfg.

To convert a Marlin value, rotation_distance = full steps × microsteps / steps per mm. The rotation distance calculator does that in both directions.

RepRapFirmware (Duet). Put the M92 line in config.g. Duet3D’s docs say values set by M92 are reset to the ones in config.g at power on. From RepRapFirmware 2.03, its S parameter gives the microstepping the values assume, as in M92 X80 Y80 Z400 S16. Without it, the values are taken at the microstepping currently set by M350.

The extruder. E-steps come from a measured test extrusion, not from a belt or screw. Use the e-steps calculator on Marlin and the rotation distance calculator on Klipper.

Travel per step: the theoretical resolution

Travel per microstep is 1 / steps per mm: 12.5 µm at 80 steps/mm and 2.5 µm at 400. A full step moves a 40 mm per turn belt axis 0.2 mm and a T8 Z axis 0.04 mm.

That microstep figure is the smallest move the firmware can command, not a guaranteed position. Monolithic Power Systems, a stepper driver maker, gives the incremental torque of a single microstep as the full-step holding torque × sin(90° / microsteps). That is about 20% at 1/8, 10% at 1/16 and 5% at 1/32. Whether a single microstep moves the axis at all depends on friction, and MPS concludes that in some cases more microsteps do not improve accuracy.

On Z, full steps matter: Josef Prusa’s RepRap calculator picks layer heights so that the axis moves only in full steps. With a T8 screw and a 1.8° motor that means multiples of 0.04 mm, such as 0.12, 0.16, 0.2, 0.24 and 0.28 mm. The calculator above shows that step for your screw. For the layer height itself, use the layer height calculator.

Published · Figures last checked

Sources

  1. Klipper documentation, Rotation distance (accessed 2026-10-18)
  2. Klipper documentation, Configuration reference: stepper and CoreXY kinematics (accessed 2026-10-18)
  3. Klipper documentation, G-Codes (supported standard commands) (accessed 2026-10-18)
  4. Klipper example config, Creality Ender 3 (printer-creality-ender3-2018.cfg) (accessed 2026-10-18)
  5. Voron Design, Voron 2.4 reference printer.cfg (Octopus) (accessed 2026-10-18)
  6. Voron Design, Voron Trident reference printer.cfg (Octopus) (accessed 2026-10-18)
  7. Marlin, M92: Set Axis Steps-per-unit (accessed 2026-10-18)
  8. Marlin, Configuring Marlin (steps per mm, calibration links) (accessed 2026-10-18)
  9. Marlin source, planner.cpp (CoreXY motor A = X + Y, motor B = X - Y) (accessed 2026-10-18)
  10. Creality, Ender-3 Marlin firmware, Configuration.h (DEFAULT_AXIS_STEPS_PER_UNIT) (accessed 2026-10-18)
  11. Prusa Research, Prusa-Firmware MK3S variant (MK3S.h) (accessed 2026-10-18)
  12. Duet3D documentation, G-code dictionary: M92 Set axis steps per unit (RepRapFirmware) (accessed 2026-10-18)
  13. Gates, Light Power & Precision Drive Design Manual (GT2, MXL, XL and HTD pitches) (accessed 2026-10-18)
  14. Josef Prusa, RepRap calculator (belt and lead screw presets, optimal layer height) (accessed 2026-10-18)
  15. Phidgets, Ball Screw SFU01204 x 800mm w/Nut (screw lead) (accessed 2026-10-18)
  16. Phidgets, Ball Screw SFU01605 x 500mm w/Nut (screw lead) (accessed 2026-10-18)
  17. RepRap wiki, Triffid Hunter's Calibration Guide (XY and Z steps per mm) (accessed 2026-10-18)
  18. Ellis' Print Tuning Guide, Misconceptions (measuring printed parts) (accessed 2026-10-18)
  19. Monolithic Power Systems, Why Microstepping Isn't as Good as You Think (accessed 2026-10-18)