How to Setup CNC Machine: A Step-by-Step Shop Floor Guide
This page walks through how to setup CNC machine for milling and turning work: homing, workholding, tool data, offsets, dry run, and first-article checks. It is written for machinists, setup technicians, and engineers who need a repeatable procedure instead of a trial-and-error run. Read it before your next first cut, and you will know which step to slow down on and which mistake scraps the part.

In this article
- 1
- 2
- 3
- 4
- 5
- 6
- 7
Key takeaways
Prepare the machine, the stock, and the paperwork
A setup starts at the bench, not at the control panel. Read the drawing, the operation sheet, and the CAM output together and confirm they agree on tool numbers, stock size, and datums. If the drawing calls out a datum on the third face and the CAM file references the first face, you will find out after the first cut, not before.
Check the machine itself. Guards in place, way covers intact, spindle taper clean, coolant level and concentration within range. Confirm the emergency stop works on every axis. Verify the air pressure at the machine regulator and the hydraulic pressure on the vise or chuck. A drop in clamping pressure mid-cut moves the part and destroys the tool.
Inspect the stock. Measure it in three places with a caliper and confirm the actual size is inside the CAM stock allowance. Remove burrs and scale from the clamping faces; a 0.2 mm burr under the vise jaw tilts the part and puts the first operation out of square. Write the actual stock size on the setup sheet so the next shift does not have to re-measure.
Stage the tools. Each tool goes into the holder with the correct stick-out, then gets measured for length and diameter. Clean the taper and the holder face before assembly. A chip trapped between the holder and the spindle face can shift the tool by 0.01–0.02 mm and it will not show up until dimensional inspection.
- 1Datum agreementDrawing, CAM, and setup sheet must reference the same face and the same corner.
- 2Stock allowanceLeave 0.3–0.5 mm on faces that will be finished later; less for ground or pre-machined stock.
- 3Tool stick-outKeep it as short as the geometry allows; every extra 10 mm of overhang increases deflection.
Home the axes and set work offsets for how to setup CNC machine
Return every axis to its machine reference point. On most mills this is a Z-axis return first, then X and Y, to keep the tool clear of the fixture. On lathes, home the turret and confirm the chuck is clear. The machine coordinate system established here is the base for every offset you set later, so do not skip it or trust yesterday's position.
Set the work offset by touching off the part or the fixture with a edge finder, a 3D taster, or a probe. For a probe, use a calibrated stylus and let the control write the offset; for manual touch-off, use a spindle speed of 500–800 rpm and a feed around 50 mm/min to avoid marking the surface. Record which corner and which face you touched. Ambiguity here is the most common cause of a mirrored or shifted first part.
On a lathe, set the Z work offset from a faced surface and the X offset from a turned diameter. Take a light cut, measure with a micrometer, and enter the difference. Do not trust a pre-set value from a previous job unless the tool holder and insert are identical.
Confirm the offsets by moving to a known point in the program and reading the distance-to-go. If the control says the tool is 3 mm from the part and your ruler says 3 mm, the offset is good. If they disagree, stop and re-measure. Chasing a bad offset with the feed override is how tools break.
- 1Probe over touch-offA calibrated probe removes operator feel from the offset and repeats within 0.005 mm.
- 2Record the cornerWrite down which corner and face the offset references, plus the tool number used.
- 3Verify distance-to-goCompare the control readout with a physical check before the first cut.
What changes between a mill setup and a lathe setup
On a mill, the part stays still and the tool moves, so workholding stiffness and tool stick-out dominate the result. On a lathe, the part rotates, so chuck balance, jaw grip, and bar support matter more. A 300 mm bar hanging 150 mm out of a chuck will deflect under cutting force even with a light finishing pass.
Milling setups often need multiple operations, which means re-datuming between them. Use a common reference feature, such as a bored hole or a machined face, so the second operation locates from something the first operation produced. If you locate from raw stock, you carry the stock tolerance into the finished part.
Lathe setups usually run longer with fewer interruptions, so thermal drift becomes a factor. On a part held to ±0.005 mm, check the first article, then re-check after 20–30 minutes of running. A spindle that grows 0.01 mm over an hour is normal; compensate with a small offset change rather than fighting it.
Five-axis setups add rotary axis offsets and center-of-rotation values. Those numbers are machine-specific and must be calibrated, not guessed. If the rotary center is off by 0.05 mm, a tapered wall on a 5-axis part will show it as a step at the tool change.
- 1Mill: stiffness firstShort tool stick-out and a rigid fixture beat a slower feed every time.
- 2Lathe: grip and balanceCheck jaw grip on thin walls and balance the chuck for higher spindle speeds.
- 35-axis: calibrate the centerVerify rotary center-of-rotation before trusting any multi-axis toolpath.
Common setup mistakes and how to catch them early
The most expensive setup error is a wrong work offset. It usually shows up as a part cut 10 mm off the datum, or as a tool driving into the fixture. The dry run at 0.1 mm above stock catches most of these before the spindle is under load. If you skip the dry run, you are relying on the control, the CAM file, and the operator all being correct at the same time.
The second most common error is a tool that does not match the offset table. A 6 mm end mill in position 4 with the length of a 10 mm drill will either cut air or bury itself in the part. Verify one tool by touching off on a known surface and comparing the readout. That single check takes two minutes and prevents most crashes.
Workholding distortion is quieter but just as costly. A thin-walled aluminum housing clamped too hard will measure correctly in the vise and spring out of tolerance when released. Check the part after unclamping, not just in the fixture. For walls under 3 mm, use soft jaws machined to the part profile or a vacuum fixture.
Thermal and chip issues build up over a run. Chips recut in a pocket raise the cutting temperature and change the finish from Ra 0.8–1.6 μm to something visibly torn. Confirm chip evacuation on the first part and check the coolant nozzles point at the cutting zone, not at the fixture.
- 1Wrong offsetSymptom: part cut off datum or tool into fixture. Fix: dry run and distance-to-go check.
- 2Tool number mismatchSymptom: air cut or sudden overload. Fix: verify one tool length in the spindle.
- 3Clamping distortionSymptom: in-tolerance in the vise, out after release. Fix: measure after unclamping.
- 4Poor chip evacuationSymptom: torn finish and rising temperature. Fix: aim coolant and add a peck or dwell.
Step by step: how to setup CNC machine from power-on to first cut
Follow the order. Skipping a step moves the error downstream where it costs more.
- 1Power up and home all axesSwitch on the machine and control, release the emergency stop, then command Z home first, followed by X and Y. On a lathe, home the turret and confirm the chuck is clear. Do not jog the machine before homing; the control may not know where it is.
- 2Mount and indicate the workholdingBolt the vise or fixture to the table, then indicate the fixed jaw or the locating face. Keep runout under 0.02 mm for general work and under 0.005 mm for tight-tolerance parts. Tighten in a cross pattern and re-check after tightening.
- 3Load the stock and confirm clampingSeat the part against the locating face and clamp it. Use a torque wrench on the vise if the material is thin; 6061 aluminum at 6 mm wall thickness distorts above roughly 20 N·m on a 150 mm vise. Tap the part down with a soft mallet and re-check the seating.
- 4Measure and enter tool dataMeasure each tool on the presetter or in the spindle. Enter length and diameter into the offset table and match tool numbers to the CAM file. Verify one tool by touching it to a known surface and comparing the readout with the entered length.
- 5Set work offsets and verifyTouch off or probe the datum, write the offset, then move to a program point and check distance-to-go. For a mill, confirm X, Y, and Z separately. On a lathe, confirm X from a turned diameter and Z from a faced surface.
- 6Dry run with Z raisedRaise Z by 0.1 mm above the stock and run the program with rapid override reduced to 25%. Watch the distance-to-go display at every tool change. A wrong tool number or a missing offset shows up here, not in the cut.
- 7Cut the first article and measureRun the first part at reduced feed, around 50–70% of the programmed value, and watch for chatter and chip evacuation. Measure the critical features immediately and adjust offsets before running the rest of the batch.
- 8Sign off and documentRecord the final offsets, tool numbers, and any adjustment made. Note the actual stock size and the first-article results. The next setup on this job starts from this sheet, not from zero.
Typical starting values by operation and material
These are starting points for roughing and finishing in common setups. Adjust to the tool, the holder, and the machine.
| Operation | Material | Surface speed | Feed per tooth |
|---|---|---|---|
| Face milling, rough | 6061 aluminum | 300–500 m/min | 0.10–0.20 mm |
| Face milling, finish | 6061 aluminum | 500–800 m/min | 0.05–0.10 mm |
| End milling, rough | 1018 steel | 100–150 m/min | 0.05–0.12 mm |
| End milling, finish | 4140 steel | 150–200 m/min | 0.03–0.08 mm |
| Turning, rough | 304 stainless | 120–180 m/min | 0.15–0.25 mm/rev |
| Turning, finish | 304 stainless | 180–250 m/min | 0.05–0.10 mm/rev |
| End milling, rough | Ti-6Al-4V | 40–60 m/min | 0.04–0.08 mm |
The setup is done when the first article measures correctly
Do not release a run until one part has been cut, measured, and signed off against the drawing. Everything before that is preparation, not production.
Setup questions engineers ask
How long should a CNC setup take?
It depends on the number of operations and how much fixturing is involved. A simple 3-axis milling job with one vise and a few tools can be ready for the first cut in under an hour. A multi-operation 5-axis job with custom fixtures and probing can take most of a shift.
The time that matters is not the setup itself but the first-article loop. Budget for one or two adjustment cycles after the first part is measured.
Should I use a probe or touch off manually?
Use a probe when the machine has one and the part geometry allows it. A calibrated probe repeats within about 0.005 mm and removes operator feel from the offset. Manual touch-off with an edge finder is fine for general work at ±0.05 mm, but it depends on spindle speed, feed, and how the operator judges contact.
For tight-tolerance work, probe if available, then verify with a distance-to-go check before cutting.
What is the biggest cause of scrapped first parts?
A work offset that does not match the CAM datum. It can come from touching off the wrong corner, from a fixture that moved after the offset was set, or from a CAM file that references a different face than the setup sheet.
The dry run at 0.1 mm above stock catches most of these cases. So does writing down which corner and face the offset references.
How do I set up a thin-walled part without distortion?
Use soft jaws machined to the part profile, or a vacuum fixture, and reduce clamping force. For 6061 aluminum at 6 mm wall thickness, keep vise torque below roughly 20 N·m on a 150 mm vise and re-check the part after unclamping.
If the wall is under 3 mm, consider supporting the inside with a machined plug or leaving a sacrificial rib that is removed in a later operation.
Do I need to re-home the machine between jobs?
Not always, but you should verify the reference position before trusting offsets from a previous job. A machine that has been powered down, or that has had an alarm, may have lost its reference.
If the machine stayed powered and no axis was moved by hand, the reference is usually still valid. Re-home when in doubt; it takes a few minutes and removes a whole class of errors.
How do I hand a setup over to the next shift?
Leave a setup sheet that lists the operation, the fixture, the tool numbers, the offsets, the actual stock size, and the first-article results. Include any adjustment made during the run and why.
A written handover is the difference between a job that restarts in ten minutes and a job that restarts from scratch.
Need parts machined without setting up a machine yourself?
Send your drawings and we will quote with a free DFM analysis within 12 hours. Production can start within 24 hours, and every part is inspected before it ships.
12-hour quote100% inspectionNo minimum order quantityNDA available on request