GreatLight CNC Machining Factory logo
CNC Machining
Rapid Prototyping
Materials
Industries
News
About GL

Get Instant Quote

CNC setup guide

How To Set Home Position In CNC Machine

This guide is for engineers, machinists and buyers who need to know how a machine finds its reference point and why that number decides the tolerance of every part after it. We cover the three homing modes, the grid shift check, the daily verification routine and the mistakes that quietly move a job out of spec. Read it once, then use the checklist at the end of every shift.

±0.005 mm tolerance16 five-axis centersISO 9001 / IATF 16949No minimum order
how to set home position in cnc machine
Quick answer

Key takeaways

Home is a fixed machine pointIt is set by limit switches or an absolute encoder, not by the part. Work offsets G54–G59 sit on top of it.
Repeatability beats accuracy hereA home that returns to the same spot within 0.002 mm every morning matters more than the absolute number.
Grid shift is the usual culpritAfter a crash or a battery change, the grid shift value drifts and every part runs offset by the same amount.
Verify daily, not yearlyA ten-minute check with an indicator on the table catches drift before the first good part is scrapped.
Absolute encoders change the routineMachines with absolute feedback do not need a full homing cycle, but they still need the reference check.
What home actually is

What the home position controls on a CNC machine

Every coordinate on a CNC machine hangs off one fixed point. The machine home, also called machine zero or the reference point, is a position on each axis rail defined by a limit switch, a proximity sensor or an absolute encoder reading. The controller knows exactly where that point is in machine coordinates. Everything else, the workpiece zero in G54, the tool length offsets in H registers, the fixture offsets, is measured as a distance from it.

That is why a home error is so expensive. If the reference point lands 0.010 mm away from where it landed yesterday, that error is not local to one feature. It shifts the whole coordinate frame, so every pocket, every hole and every face moves with it. On a job held to ±0.005 mm, a 0.010 mm frame shift is already twice the total tolerance, and no amount of careful cutter compensation will recover it.

For buyers reading this, the practical question is not whether a supplier owns a machine with a homing routine. Almost every VMC and turning center has one. The question is whether the shop verifies that routine on a schedule, records the result, and stops production when the number moves. That is the difference between a machine that is capable and a machine that is merely available.

It helps to separate three numbers that people often mix up. Machine home is fixed by hardware and should not move. Work offset is set by the operator to place the part. Tool offset is set by touching off each tool. Home is the only one of the three that the operator cannot legitimately adjust, and it is the one that causes the widest damage when it is wrong.

Modes

Three ways a machine finds its reference point

Manual homing relies on the operator jogging each axis onto a physical mark and zeroing the display. It is common on older knee mills and on some retrofit controls. Repeatability depends on eyesight and feel, and in practice it lands within 0.02–0.05 mm at best. Use it for rough work, setup checks and non-critical fixtures. Do not use it for anything with a tight true position callout.

Switch homing is the standard on modern vertical and horizontal machining centers. The axis rapids toward the switch at a fast feed, decelerates, backs off, then approaches again at a slow, fixed feed, typically 10–50 mm/min, and latches the first switch signal. The slow second pass is what gives repeatability, usually 0.001–0.005 mm on a healthy machine. The approach direction must always be the same, because switch hysteresis makes a reverse approach land somewhere else.

Absolute encoder homing removes the cycle entirely. A battery-backed or multi-turn absolute encoder remembers the axis position through power-off, so the control already knows where it is when you switch on. No rapids to the switch, no latching, no warm-up pass. The trade-off is that the reference is now stored electronically, and a dead battery or a parameter reload can silently change it. Machines with absolute feedback still need a periodic physical check against a known artifact.

The mode your machine uses decides your daily routine. Switch homing needs a full cycle and a first-part check. Absolute feedback needs a position verification against a reference feature, because a wrong stored value looks exactly like a correct one on the screen.

Grid shift

Grid shift and reference return on a set home position in cnc machine

The grid shift parameter, often labelled grid offset or reference counter offset, tells the control how far the electrical latch point sits from the mechanical home you want to use. When the axis hits the switch, a hardware counter latches a position pulse. The control then adds the grid shift value to place the machine coordinate zero at the intended spot. Change the grid shift by 0.100 mm and the whole machine frame moves 0.100 mm, with no alarm and no visible symptom.

Grid shift changes after three common events: a hard crash that moves the switch bracket or the coupling, a low or dead encoder battery on an absolute system, and a control parameter restore from an old backup. In each case the number on the screen still reads zero, because zero is defined wherever the control was told it is.

The check is straightforward. Mount a dial indicator on the spindle or the table, sweep a known reference surface such as a vise jaw, a tombstone face or a granite square, and write down the reading in machine coordinates. Repeat it after any crash, battery change or parameter edit, and compare. A shift of 0.005 mm or more deserves investigation before the next production run starts.

On five-axis machines the same idea applies to the rotary axes. The C-axis and A-axis reference must be checked against a known feature, because a rotary home error rotates every feature around the centerline. A 0.010° error on a 200 mm radius becomes roughly 0.035 mm of linear error at the part surface, and it grows with radius.

Thermal effects

Warm-up and thermal drift around the reference point

A machine that has been sitting overnight is not the same machine it will be at 2 pm. The ballscrew, the spindle and the bed grow as they warm up, and the growth is not uniform. A typical vertical machining center can move 0.020–0.050 mm at the tool tip over the first two hours of running, even with the home point unchanged.

This is why the home position should be re-verified after the warm-up cycle, not before. Run the spindle at a moderate speed, move the axes through their normal range of travel for 15–30 minutes, then re-home and re-check the reference. On tight work, a shop that homes cold and cuts immediately is measuring a moving target.

Coolant temperature matters too. A machine that runs warm coolant through the bed reaches a stable state faster on the second shift than on the first. If your supplier runs lights-out production, ask how the warm-up is handled between unattended cycles and whether the reference is rechecked when the operator returns.

At GreatLight we run 127 high-precision CNC machines across three wholly-owned plants, including 16 simultaneous 5-axis machining centers, and hold ±0.005 mm on production parts. That tolerance is only meaningful if the reference frame is stable and checked, which is why the homing and warm-up routine is written into the setup sheet rather than left to habit.

Errors

Common mistakes when you set home position in cnc machine

The first mistake is homing once and trusting it for the whole week. Switches wear, brackets loosen and chips accumulate. A weekly check is not enough for tight work. Daily is the practical minimum, and after any crash it is immediate.

The second is homing from the wrong direction. Switch hysteresis means the latch point differs by a few microns depending on which way the axis approaches. Always let the control run its own sequence. Jogging the axis close to the switch first, so the slow pass is shorter, changes the result.

The third is forgetting the tool offsets. A corrected home frame invalidates every tool length and every work offset measured against the old frame. Operators who re-home and then run the previous program without re-touching will scrap the first part every time. It is a five-minute job that saves a whole batch.

The fourth is ignoring the rotary axes. Most of the attention goes to X, Y and Z. On a 5-axis job the A and C reference matters just as much, and it is harder to see. Sweep a known feature on the trunnion or the table and compare it with the recorded value, the same way you would for a linear axis.

Procedure

How to set home position in cnc machine: 7 steps

  • 1
    Clean and inspect the switchesWipe chips and coolant off every limit switch, dog and proximity sensor on X, Y, Z and any rotary axis. Check that the bracket bolts are tight and the switch roller moves freely. A chip packed against a dog is the simplest cause of a half-millimetre home error.
  • 2
    Warm up the machineRun a 15–30 minute warm-up cycle through the normal travel range at moderate spindle speed. On a cold morning, extend it. Homing a cold machine and homing a warm one can give different readings on the same day.
  • 3
    Run the reference returnCall the reference return for each axis in the control, either one axis at a time or the full sequence. Let the machine complete the slow second approach without interruption. Do not hand-wheel an axis during the latch pass, and do not skip the deceleration by jogging.
  • 4
    Confirm the machine coordinatesAfter the return, check that each axis reads the expected machine coordinate, usually zero or a fixed reference number. A reading that is off by a round number such as 0.100 mm or 1.000 mm points at a grid shift or parameter problem, not a mechanical one.
  • 5
    Verify against a physical referenceSweep a dial indicator across a known surface such as a vise jaw or tombstone face and record the reading. Compare it with the last recorded value. Anything beyond 0.005 mm should be investigated before production starts.
  • 6
    Re-touch the tool and work offsetsAfter any home correction, re-touch the tools and reset G54. Tool length offsets are measured from the machine frame, so a frame change invalidates every one of them. Skipping this step is the most common cause of a first-article failure.
  • 7
    Cut a test feature and record the resultMachine a small test pocket or a reference boss, measure it, and log the deviation together with the machine number, date and operator. The log turns a one-off check into a trend you can act on before parts are scrapped.
Decision table

Homing mode compared: what to use and when

Repeatability figures are typical values for a healthy machine, not guarantees.

ModeTypical repeatabilityBest fitWatch out for
Manual marks0.02–0.05 mmRough work, setup checksOperator eyesight and feel
Switch homing0.001–0.005 mmProduction VMC and turningChips on dogs, reverse approach
Absolute encoderDepends on stored valueLights-out and 5-axisDead battery, old parameter restore
Rotary axis reference0.005° and finer5-axis and mill-turnError grows with part radius
Cold machine check0.020–0.050 mm driftNot recommendedThermal growth over first 2 hours
Warm machine checkStable after 30 minutesTight tolerance workCoolant temperature swings
Post-crash recheckMandatoryAny machine that has crashedGrid shift moved silently

A verified reference is the cheapest tolerance you can buy

Home position is not a setting you finish once. It is a number you confirm every day, after every crash and after every warm-up. Get that routine right and the rest of the process has a stable frame to work from. Skip it and no tolerance on the drawing will hold.

FAQs

Frequently asked questions

How often should the home position be checked?

Daily before the first production part, after every crash, after any encoder battery change, and after a parameter restore. For work held tighter than ±0.010 mm, add a check after the warm-up cycle as well.

The check itself takes about ten minutes with a dial indicator and a known reference surface. It costs far less than scrapping a batch.

Why does the machine read zero but still cut offset?

Because zero is defined by the grid shift parameter, not by the physical switch. If the grid shift value drifts, the control still shows zero at the new location. The machine has no way to know the frame moved.

Compare a physical reference reading with your log. A consistent offset across all features points at the frame, not at the tool or the program.

Can a machine lose its home position overnight?

On a switch-based system, the stored position is gone at power-off and rebuilt at the next reference return, so the risk is limited to switch condition. On an absolute encoder system, a weak battery can lose the multi-turn data while the machine is off, and the control may come up with a wrong reference.

Replace batteries on the manufacturer's interval, not when the alarm appears.

Does home position affect five-axis accuracy more than three-axis?

Yes, because rotary errors are amplified by radius. A small angular error at the C-axis becomes a larger linear error at the part surface, and the effect grows with part size. A 0.010° error at a 200 mm radius is roughly 0.035 mm.

That is why the rotary reference deserves its own check, separate from the linear axes.

What should be recorded in the home position log?

Machine number, date, operator, warm-up duration, machine coordinate readings for each axis, indicator reading against the reference surface, and any offset applied. Keep the last few months so you can spot a slow drift before it becomes a failure.

A trend is more useful than a single pass or fail result.

How does a supplier's homing routine affect my parts?

It sets the ceiling on the tolerance the shop can hold. A machine that is homed and verified daily can hold ±0.005 mm; one that is homed once a month cannot, no matter what the specification sheet says.

Ask for the setup and verification records along with the inspection report. The record tells you more than the machine model.

Send us your drawings and tolerance callouts

Upload a STEP file and we will return a quotation and a free DFM analysis within 12 hours. Parts ship in 3–5 days, with 100% inspection before shipment and reports on request.

12-hour quote±0.005 mm toleranceNo minimum orderNDA on request

Follow us

More machining notes from the shop floor

We publish setup notes, tooling trials and inspection data from the factory floor.

FacebookTikTokYouTubeLinkedInInstagramThreadsPinterest

Trusted by engineers and manufacturers worldwide

Tesla Ford Motor Company BYD Auto Denso Magna International Boeing Airbus Medtronic KUKA FANUC