Tuning a CNC Machine: Quick Tips for Holding Tolerance
Tuning a CNC machine is mostly measuring before you cut, not turning screws until the part looks right. These seven checks cover the geometry, spindle, thermal and backlash errors that show up as scrap on five-axis work. Use them when a machine drifts, after a move, or before a tight-tolerance run.

In this article
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
What matters most when tuning a CNC machine
Which machines and parts this tuning routine fits
Tuning a CNC machine is a maintenance task with a measurable goal: bring the machine back to the accuracy it had when it was installed. On a three-axis mill the work is mostly squareness, spindle runout and backlash. On a five-axis center you add rotary pivot center position and the kinematic model, which is where most shops lose time.
The routine below suits vertical mills, mill-turn centers and simultaneous five-axis machines working to ±0.005 mm. It also fits older machines that still hold ±0.02 mm on loose-tolerance work, where you only need to confirm nothing has shifted after a move or a crash.
It does not replace a laser interferometer or ballbar service. If linear positioning error over 500 mm exceeds 0.03 mm, or a rotary axis shows more than 0.02 mm of radial runout at the table face, call the OEM. Hand tuning will not fix a worn guideway or a failing encoder.
Parts that need this most: thin-wall housings, long shafts with tight concentricity, five-axis impellers, and any feature machined in two setups where the second setup picks up the first. If the part has one face, two holes and a ±0.1 mm callout, a quick check is enough.
Pre-tune baseline: what to record before touching anything
Write down the starting numbers. Without them you cannot tell whether your adjustment helped or just moved the error somewhere else. Record the date, ambient temperature and spindle hours alongside each value.
Start with level and foundation. A machine that has settled on a soft floor pad will twist. Check the level at the four corners and the center of the bed with a precision level, and compare against the installation sheet. Do this with the table at mid-travel, not parked at one end.
Then record spindle runout at the taper, tool holder runout with a test bar, and axis backlash on X, Y and Z in both directions. On a five-axis machine, add the rotary zero position and the distance from spindle gauge line to the table center.
Finally, cut a test part and measure it. A stepped block with a bored hole and a faced shoulder tells you more in twenty minutes than an hour of static checks. Keep that part. It becomes the reference for the next tune.
- 1Log before and after
- 2Use a warm machine
- 3Same probe, same setup
Axis geometry: squareness and rotary pivot center
Squareness error between X and Y shows up as a taper on any long face. Set a granite square or a cylinder square on the table, indicate along one edge, then the other. On a typical vertical mill the target is under 0.010 mm over 300 mm. Above 0.020 mm, a 200 mm long part will be out of parallel by more than 0.013 mm before you even start cutting.
On five-axis machines, pivot center position is the number that ruins parts quietly. The distance from the spindle gauge line to the C-axis center, and the offset of the A or B axis from the table center, both feed directly into the post-processor. If that value is off by 0.05 mm, a tilted feature will land off by roughly the same amount, and no amount of tool compensation will correct it.
The standard check is a ball in the spindle and a dial indicator on the table, or a calibrated sphere swept through a series of rotary positions. Record the center as X, Y and Z offsets relative to the machine zero. Repeat it after any crash, spindle replacement or rotary table service.
Do not chase the last micron on squareness while the rotary center is out by 0.05 mm. Fix the larger error first, then re-measure. Errors add up, but they do not cancel.
Spindle, tool holder and tool setting errors
Spindle taper runout is the base of every accuracy chain. Check it with a test bar at 50 mm and 300 mm from the gauge line. A common shop limit is 0.005 mm at 50 mm; if the 300 mm reading is more than triple the 50 mm reading, the taper or the bar is damaged.
Tool holder runout adds to that. A worn ER collet nut or a dirty taper seat can push a 6 mm end mill out by 0.02 mm, which shows up as a slot that is wide on one side. Clean the taper with a lint-free wipe and check the holder before blaming the machine.
Tool length and diameter must be set the same way every time. Offline presetters and in-machine touch setters disagree by 0.01-0.03 mm on a regular basis. Pick one method per job, and if you switch, re-cut the first part and measure.
Thermal growth closes the loop. A spindle running at 12,000 rpm for an hour can grow 0.02-0.04 mm in Z. Warm up at the working speed, then set tool lengths. Setting tools on a cold spindle is a common cause of a first-article failure on a tight Z callout.
Backlash, backlash compensation and thermal drift
Backlash is lost motion when the axis reverses. Measure it with an indicator on the table and a commanded move of 0.050 mm in each direction, or with a ballbar if you have one. On a healthy ball screw and preloaded nut, expect under 0.005 mm. Above 0.015 mm on a finishing axis, the screw, nut or thrust bearing needs attention.
Backlash compensation in the controller masks the symptom. It works until the wear becomes uneven along the screw, then the compensation is wrong at both ends. Use it as a stopgap, not a repair. Re-measure at three positions along the travel: near the column, mid-travel, and near the far end.
Thermal drift is a slower error and often gets blamed on backlash. Run the machine through a warm-up cycle, then measure a reference feature every 30 minutes for two hours. If the reading walks in one direction, you have a thermal issue, not a mechanical one.
For long cycles, keep the coolant temperature stable and avoid opening the shop door onto a cold machine. A 5 °C change in ambient air can move a 400 mm steel part by roughly 0.02 mm before the machine even moves.
How to prove the tune worked, and when to hand it to the OEM
A tune is only finished when a part proves it. Cut the same verification block you used before the adjustment and measure it with the same tools. Compare feature by feature: bore size, shoulder height, slot width, hole position. If the numbers are inside ±0.005 mm and repeat across three parts, the machine is ready for production work.
Repeatability matters more than a single good part. Run three parts back to back without touching offsets. If part one and part three differ by more than 0.010 mm, you still have a thermal or backlash problem, not a setting problem.
There is a clear line where hand tuning stops being useful. Linear positioning error over 500 mm above 0.03 mm, rotary radial runout above 0.02 mm, or a spindle taper that fails a test bar check all point to a component that needs replacement or a laser calibration service.
After any crash, run the full routine rather than the one check that looks wrong. A crash rarely damages only one axis. The rotary center and squareness are the two that move most often, and both are easy to confirm in under an hour.
A seven-step tuning routine you can run in half a day
Work in order. Each step assumes the previous one is done.
- 11. Warm up and record conditionsRun the spindle at the working speed for 20-30 minutes and exercise all axes through their full travel. Write down ambient temperature, spindle hours and the last calibration date. Do not adjust anything on a cold machine.
- 22. Check level and foundationUse a precision level at the four corners and the bed center with the table at mid-travel. Compare to the installation sheet. If a pad is loose or the floor has moved, fix that before anything else.
- 33. Measure spindle and holder runoutIndicate the taper with a test bar at 50 mm and 300 mm. Target under 0.005 mm at 50 mm. Then check a loaded tool holder. Clean the taper and re-check before you record a bad number.
- 44. Measure backlash in both directionsCommand 0.050 mm moves and read the indicator. Record X, Y and Z, both directions, at three positions along the travel. Flag anything above 0.015 mm on a finishing axis.
- 55. Verify squareness and rotary pivot centerCheck X-Y squareness with a granite or cylinder square; target under 0.010 mm over 300 mm. On five-axis machines, sweep a ball or use a calibrated sphere to re-establish the rotary center offsets and update the kinematic model.
- 66. Set tool lengths on the warm machineUse one method only: presetter or in-machine setter. Re-set every tool in the job. If the job has a tight Z callout, cut a test feature and measure before running the batch.
- 77. Cut a verification part and compareMachine a stepped block with a bored hole, a faced shoulder and a slot. Measure all features and compare with the baseline part from the last tune. If the numbers moved, you know which step to revisit.
Symptom, likely cause and what to do
Use this before you start turning screws.
| Symptom on the part | Likely cause | First check | Action |
|---|---|---|---|
| Taper on a long face | X-Y squareness off | Granite square over 300 mm | Re-level, then re-check squareness |
| Slot wide on one side | Tool holder runout | Indicator on loaded holder | Clean taper, replace collet nut |
| Hole position shifts when tilted | Rotary pivot center off | Ball sweep in spindle | Re-establish center, update post |
| First part out on Z, later parts fine | Cold spindle tool setting | Spindle temperature log | Warm up, re-set tool lengths |
| Size walks during a long cycle | Thermal drift | Measure every 30 minutes | Stabilize coolant and shop air |
| Size differs on climb vs conventional | Backlash | 0.050 mm reversal test | Check screw, nut, thrust bearing |
| Random finish marks on a face | Spindle or axis vibration | Runout plus ballbar if available | Call OEM if runout is high |
Questions engineers ask about machine tuning
How often should we tune a CNC machine?
For machines running tight-tolerance work, run the short version monthly: spindle runout, backlash and a verification part. Run the full routine after a move, a crash, a spindle change or any rotary table service.
Machines on loose-tolerance work can go quarterly, but keep a baseline part from the last tune so you can compare numbers instead of guessing.
Can backlash compensation replace a repair?
No. Compensation is a controller offset that assumes a constant lost motion. Wear is rarely constant along the screw, so the offset is right at one end of travel and wrong at the other.
Use it to keep production running until a planned repair, and re-measure at three positions to see how uneven the wear has become.
Why do first articles fail on Z but later parts pass?
Tool lengths were usually set on a cold spindle. The spindle grows 0.02-0.04 mm in Z after an hour at high rpm, so a cold-set tool cuts shallow on part one and correct on part ten.
Warm up at the working speed, then set tool lengths. On tight Z callouts, cut a test feature and measure before starting the batch.
Do we need a ballbar or laser to tune a machine?
Not for a routine tune. A test bar, a precision level, a granite square, an indicator and a verification part cover most of what you need, including squareness and backlash.
A ballbar or laser becomes necessary when you need to separate servo error from geometry error, or when linear positioning error is large enough that the OEM needs the data.
What temperature should the shop be for tight work?
A stable temperature matters more than a specific one. Keep the shop within a few degrees of the temperature the machine was calibrated at, and avoid opening doors onto a cold machine.
For steel parts around 400 mm long, a 5 °C ambient change moves the part roughly 0.02 mm. That is enough to lose a ±0.005 mm callout before the machine contributes anything.
Can we tune a machine without stopping production?
The measurement steps can run between jobs, but the adjustment and verification steps need the machine. Plan a half day for the full routine on a five-axis center.
If the machine is on a critical job, do the warm-up and measurement first, then schedule the adjustment for the next gap so you are not verifying a half-finished tune under deadline pressure.
Send us your drawing and we will quote the machining
Upload your CAD file and we reply with a quotation and a free DFM analysis within 12 hours. Tolerances to ±0.005 mm, 100% inspection before shipment, and no minimum order quantity from one prototype to 10,000+ parts.
12-hour quote±0.005 mm toleranceNo MOQNDA on request