Skip to content
Upload CAD

2026-09-30

How Heat Treatment Affects CNC Machined Metal Parts: Distortion, Tolerances and Process Planning

cnc machining

Heat treatment is often essential for precision metal components that need a specific combination of hardness, strength, wear resistance, toughness or fatigue performance.

However, heat treatment is not simply a material-property step that happens after machining.

For precision CNC machined parts, heat treatment can also affect dimensional stability, surface condition, residual stress, distortion and the final machining strategy.

A component that meets its dimensional requirements before heat treatment may not automatically meet the same requirements afterward.

This is why engineers and procurement teams should consider heat treatment during the original manufacturing planning stage rather than treating it as a separate operation.

For example, a steel component may be rough machined, heat treated, finish machined and then inspected. Another component may require a different sequence depending on its geometry, material, tolerance and required hardness.

The correct sequence depends on the application.

MFG SOLUTION supports precision manufacturing through CNC machining, CNC turning, Swiss turning, cold forging, precision casting, surface finishing and documented inspection. Its manufacturing approach considers material, tolerance, quantity, finishing and inspection requirements when determining the production route.

This guide explains how heat treatment interacts with CNC machining and what engineers should consider when specifying and manufacturing precision metal parts.


1. Why Heat Treatment Matters in CNC Manufacturing

Heat treatment changes the internal structure and mechanical properties of a metal.

Depending on the material and treatment, it may improve:

  • Hardness
  • Tensile strength
  • Yield strength
  • Wear resistance
  • Fatigue resistance
  • Toughness
  • Dimensional stability
  • Resistance to deformation during service

Common heat-treatment processes include:

  • Annealing
  • Normalizing
  • Stress relieving
  • Quenching
  • Tempering
  • Carburizing
  • Nitriding
  • Precipitation hardening
  • Solution treatment
  • Aging

The appropriate process depends heavily on the material.

For example, precipitation-hardening stainless steels such as 17-4PH can achieve different strength levels through aging treatment. MFG SOLUTION’s 17-4PH material guide explains how machining is commonly performed in the solution-annealed condition before final aging treatment.

For carbon and alloy steels, quenching and tempering may be used to achieve the required combination of hardness and toughness.

Therefore, the phrase “heat treated steel” is not sufficient engineering information.

The drawing or specification should define the required material condition or applicable standard.


2. Heat Treatment Can Change Part Dimensions

One of the most important considerations for precision machining is dimensional change.

During heat treatment, a component can experience:

  • Thermal expansion
  • Thermal contraction
  • Phase transformation
  • Residual stress redistribution
  • Localized distortion
  • Warping
  • Bending
  • Changes in hardness

The amount of dimensional change depends on factors such as:

  • Material composition
  • Heat-treatment process
  • Part geometry
  • Wall thickness
  • Cross-section changes
  • Internal stress
  • Quenching method
  • Heating rate
  • Cooling rate
  • Fixturing
  • Previous machining history

This means that a precision component should not always be machined to its final dimension before heat treatment.

In many applications, the manufacturer intentionally leaves machining allowance for a subsequent finishing operation.


3. Rough Machining vs Finish Machining

A common production strategy for heat-treated precision parts is:

Raw material → Rough machining → Heat treatment → Finish machining → Surface finishing → Inspection

The purpose of rough machining is to establish the general geometry while leaving appropriate material for later finishing.

Heat treatment can then be performed.

After the material reaches its required condition, finish machining can establish the final:

  • Diameter
  • Flatness
  • Parallelism
  • Perpendicularity
  • Concentricity
  • Bore size
  • Thread location
  • Surface finish

This strategy is particularly useful when the heat-treatment process has a meaningful risk of dimensional movement.

The exact allowance should not be selected using a universal number.

It should be determined based on:

  • Material
  • Heat-treatment method
  • Part size
  • Geometry
  • Previous production data
  • Required final tolerance

4. Why Residual Stress Matters

Residual stress is internal stress that remains inside a material even when there is no external load.

Machining can redistribute residual stress.

Heat treatment can also relieve or redistribute it.

This creates an important relationship between machining and dimensional stability.

Imagine a large aluminum or steel component with a substantial amount of material removed from one side.

The machining process may release internal stresses that were previously balanced inside the raw material.

The part may then move slightly.

Heat treatment can create another opportunity for stress redistribution.

For this reason, high-precision components should be evaluated as a complete process rather than as isolated operations.

MFG SOLUTION’s CNC machining workflow considers material condition, machining sequence, part rigidity, heat and dimensional control as part of process planning.


5. Heat Treatment of Alloy Steel Components

Alloy steels are widely used for mechanical components that require strength and wear resistance.

Common grades include:

  • 4140
  • 4340
  • 8620
  • 42CrMo4

MFG SOLUTION’s materials guidance identifies 4140 for shafts and pins, 4340 for high-fatigue-strength applications and 8620 for components requiring case-hardening capability.

Depending on the application, these materials may undergo:

  • Annealing
  • Normalizing
  • Quenching
  • Tempering
  • Carburizing
  • Case hardening

The heat-treatment condition should be specified before production.

For example, a shaft may require high surface hardness but sufficient core toughness.

In that situation, the engineer may select a case-hardening process rather than simply hardening the entire component.

The correct treatment therefore depends on how the part will function.


6. Quenching and Tempering

Quenching involves heating a material to an appropriate temperature and then cooling it relatively rapidly.

This can increase hardness but may also introduce significant internal stress.

Tempering is subsequently used to adjust the final combination of hardness and toughness.

A typical route for an alloy-steel component may be:

Rough machining → Quenching → Tempering → Finish machining → Inspection

However, the exact sequence depends on the material and geometry.

A large thin-wall component may behave differently from a compact shaft.

Therefore, heat-treatment planning should be performed together with manufacturing engineering rather than specified independently.


7. Carburizing and Case Hardening

Some components require a hard external surface while maintaining a tougher internal core.

Gears, shafts, pins and wear components can fall into this category.

Carburizing introduces carbon into the surface layer of a suitable steel.

After subsequent heat treatment, the surface can achieve high hardness while the core retains different mechanical characteristics.

A simplified production route may be:

Machining → Carburizing → Hardening → Tempering → Finish machining → Inspection

The final machining operation may be necessary because heat treatment can affect dimensions.

Critical bearing surfaces, bores or mating diameters may require final grinding or precision machining after treatment.


8. Nitriding for Wear and Surface Performance

Nitriding is another surface-hardening process.

It introduces nitrogen into the surface of suitable alloys and can improve:

  • Surface hardness
  • Wear resistance
  • Fatigue performance
  • Certain corrosion characteristics

Nitriding can be useful for components where only the surface requires enhanced hardness.

Compared with some bulk-hardening processes, nitriding can be advantageous when dimensional change must be controlled, but the actual result depends on the material, process and geometry.

Engineers should specify the required:

  • Hardness
  • Case depth
  • Material
  • Surface condition
  • Dimensional tolerance

rather than simply writing “nitrided” on a drawing.


9. Heat Treatment of Stainless Steel

Not all stainless steels respond to heat treatment in the same way.

This is an important distinction.

For example:

304 stainless steel

304 is an austenitic stainless steel and is not hardened through conventional quench-and-temper treatment.

316 stainless steel

316 is also austenitic and is generally selected for corrosion resistance rather than heat-treatable hardness.

MFG SOLUTION’s 316 material guide notes that SS 316 is not hardened through conventional heat treatment and instead gains strength primarily through cold working.

17-4PH stainless steel

17-4PH is different.

It is precipitation hardenable and can achieve high strength through appropriate aging treatment.

This illustrates why engineers should never specify heat treatment based only on the word “stainless steel.”

The exact grade is essential.


10. 17-4PH as an Example of Integrated Machining and Heat Treatment

17-4PH is a useful example because it combines corrosion resistance with high strength.

MFG SOLUTION’s 17-4PH guide identifies several commonly used conditions, including:

  • Solution annealed
  • H900
  • H1025
  • H1100

Each condition provides a different balance of strength and toughness.

For precision CNC components, a typical strategy is to machine the material in an appropriate condition before final aging.

The engineering team then needs to consider:

  • Final hardness
  • Required dimensional tolerance
  • Heat-treatment sequence
  • Machining allowance
  • Post-treatment finishing
  • Inspection

The important point is that material specification and manufacturing process cannot be separated.


11. How Heat Treatment Affects CNC Tolerances

A tolerance defines how much dimensional variation is acceptable.

For example, a drawing may specify:

  • ±0.05 mm
  • ±0.02 mm
  • ±0.01 mm
  • ±0.005 mm

The tighter the tolerance, the more carefully the complete manufacturing process must be controlled.

If heat treatment occurs between rough and finish machining, the manufacturer can potentially compensate for expected dimensional changes during final machining.

If a part is required to hold a very tight tolerance directly after heat treatment, the process becomes more demanding.

This may require:

  • Better material control
  • Controlled heat treatment
  • Stable fixturing
  • Process monitoring
  • Precision machining
  • Additional measurement
  • Potential grinding

MFG SOLUTION’s ISO tolerance resources provide guidance for interpreting general tolerance requirements and determining when tighter dimensional controls are necessary.


12. Why Geometry Influences Heat-Treatment Distortion

Part geometry has a major influence on dimensional stability.

Consider two components made from the same steel.

Part A

A compact cylindrical shaft with relatively uniform cross-section.

Part B

A large plate with:

  • Thin walls
  • Deep pockets
  • Uneven sections
  • Large changes in thickness
  • Asymmetric material removal

The second part may have a greater risk of distortion.

Uneven geometry can produce different heating and cooling behavior.

Therefore, heat-treatment planning should consider:

  • Wall thickness
  • Cross-section changes
  • Symmetry
  • Long unsupported sections
  • Holes
  • Pockets
  • Slots
  • Thin webs

This is another reason DFM should occur before production.


13. Machining Allowance After Heat Treatment

Machining allowance is the additional material intentionally left for subsequent machining.

For example, instead of machining a final bore directly to its final size before heat treatment, a manufacturer may leave a controlled amount of material.

After heat treatment, the bore can then be finish-machined.

The allowance should be large enough to remove the expected distortion or surface change but not unnecessarily large.

Excessive allowance creates:

  • Longer machining time
  • More material removal
  • Higher tooling consumption
  • Higher cost

Insufficient allowance can create a different problem:

If heat treatment moves the component beyond the available finishing allowance, the part may no longer be recoverable through machining.

Therefore, allowance planning should be based on actual process capability and historical results where available.


14. Surface Condition After Heat Treatment

Heat treatment can also affect the surface.

Depending on the process, a component may experience:

  • Oxidation
  • Scale
  • Discoloration
  • Decarburization
  • Surface hardness changes

Subsequent operations may therefore be required.

Potential processes include:

  • Grinding
  • Polishing
  • CNC finish machining
  • Shot blasting
  • Passivation
  • Electropolishing
  • Plating

For example, stainless-steel components may require passivation or electropolishing depending on the application.

MFG SOLUTION supports surface finishing processes including anodizing, hardcoat anodizing, plating, polishing and electropolishing.


15. Heat Treatment and Surface Finishing Are Different

It is important to distinguish between heat treatment and surface finishing.

Heat treatment primarily changes material properties or internal structure.

Surface finishing primarily changes surface characteristics.

For example:

Heat treatment

  • Quenching
  • Tempering
  • Aging
  • Annealing
  • Nitriding
  • Carburizing

Surface finishing

  • Anodizing
  • Plating
  • Polishing
  • Electropolishing
  • Powder coating

Some processes can overlap in function, particularly surface-hardening treatments.

However, engineers should define each requirement independently.


16. Inspection After Heat Treatment

Inspection should be planned around the final functional requirements.

Possible inspection methods include:

  • Calipers
  • Micrometers
  • Height gauges
  • Bore gauges
  • Thread gauges
  • CMM
  • Hardness testing
  • Surface roughness measurement

The inspection plan may need to verify both dimensions and material condition.

For a hardened shaft, for example, the supplier may need to verify:

  • Diameter
  • Roundness
  • Concentricity
  • Surface hardness
  • Case depth if applicable
  • Surface finish

For a complex precision component, CMM inspection may be required.

MFG SOLUTION’s manufacturing process includes dimensional inspection and documented quality controls based on part requirements.


17. Heat Treatment Documentation

For production components, documentation may be just as important as the physical part.

Depending on the customer requirement, documentation can include:

  • Material certificate
  • Heat-treatment certificate
  • Hardness report
  • Dimensional inspection report
  • First Article Inspection
  • CMM report
  • Traceability information

The required documentation should be specified before quotation.

Otherwise, suppliers may quote different scopes of inspection and documentation, making price comparisons difficult.

A clear RFQ should therefore distinguish:

What the part must achieve

from

What documentation must be supplied to prove compliance.


18. How Heat Treatment Affects Production Cost

Heat treatment contributes to total manufacturing cost in several ways.

There may be:

  • Processing charges
  • Transportation
  • Handling
  • Fixturing
  • Additional machining
  • Inspection
  • Grinding
  • Scrap risk
  • Longer lead time

The cost impact becomes more significant when parts require tight tolerances after treatment.

For example:

CNC machining → Heat treatment → Final machining → Inspection

requires more operations than simply machining a soft material to final size.

However, if heat treatment is required for functional performance, removing it to reduce cost is not a genuine cost-saving strategy.

The better approach is to optimize:

  • Material
  • Heat-treatment condition
  • Machining sequence
  • Allowance
  • Inspection
  • Production volume

19. Heat Treatment and Production Volume

Production quantity can affect the preferred process route.

For a prototype, the manufacturer may prioritize flexibility.

For larger production quantities, process stability and repeatability become increasingly important.

A high-volume steel component may use:

Automatic machining → Heat treatment → Finish machining → Automated inspection

A small prototype may instead use a more flexible CNC process.

MFG SOLUTION supports both custom precision machining and production-oriented routes including CNC turning, Swiss turning, automatic lathe, cold forging and precision casting.

The manufacturing route should therefore be evaluated against expected annual demand rather than only the first order quantity.


20. Design Considerations Before Heat Treatment

Engineers can reduce manufacturing risk by considering heat treatment during product design.

Important questions include:

Is the geometry symmetrical?

Symmetrical geometry can sometimes reduce uneven thermal behavior.

Are there major thickness changes?

Large cross-section differences may affect heat transfer and distortion.

Are extremely tight tolerances necessary before treatment?

If not, rough machining followed by heat treatment and finish machining may be more practical.

Is final surface hardness required?

If yes, the treatment should be selected according to the material and application.

Will the part require post-treatment machining?

If so, sufficient allowance must be planned.

Does the drawing specify the exact material grade?

It should.

Material family names such as “steel” or “stainless steel” are usually insufficient for production.

MFG SOLUTION’s material resources emphasize specifying the grade and condition because material selection affects machining, dimensional stability, finishing and production risk.


21. A Practical Heat-Treatment Process Flow

A typical precision steel component may follow a process such as:

1. Material receiving

Verify material grade, condition and certification.

2. Rough machining

Remove bulk material while maintaining appropriate machining allowance.

3. Stress relief if required

Reduce residual stress before subsequent precision operations.

4. Heat treatment

Apply the specified thermal cycle.

5. Post-treatment inspection

Verify hardness, appearance and critical characteristics.

6. Finish machining

Establish final dimensions and functional interfaces.

7. Surface finishing

Apply the required coating, polishing or other treatment.

8. Final inspection

Verify dimensions, surface condition and documentation.

9. Packaging

Protect precision surfaces during transport.

This sequence is not universal.

Some parts may require different routing based on material and application.


22. Common Heat-Treatment Mistakes

Mistake 1: Specifying only “heat treated”

This does not define the required material condition or hardness.

Mistake 2: Ignoring machining allowance

If heat treatment changes the part, insufficient allowance can make final correction impossible.

Mistake 3: Finishing all dimensions before treatment

Some critical dimensions may need final machining afterward.

Mistake 4: Selecting heat treatment without considering the material

Not every material responds to every treatment.

Mistake 5: Ignoring geometry

Thin walls, long shafts and uneven cross-sections can create additional distortion risk.

Mistake 6: Forgetting post-treatment inspection

A part that looks correct may still fail hardness or dimensional requirements.

Mistake 7: Treating heat treatment as a supplier-only decision

The customer should define the required functional properties and applicable standards.


23. What Engineers Should Include in an RFQ

When requesting a quotation for heat-treated CNC parts, provide:

  • Exact material grade
  • Material condition
  • Heat-treatment specification
  • Required hardness
  • Case depth if applicable
  • Critical dimensions
  • General tolerances
  • Surface finish
  • Surface treatment
  • Quantity
  • Inspection requirements
  • Documentation requirements
  • Target delivery date

For example, instead of writing:

“4140 steel, hardened”

a production drawing should define the applicable engineering requirement.

This gives the supplier enough information to evaluate machining sequence, heat treatment and inspection.

MFG SOLUTION’s CNC quotation process asks customers to provide the drawing, material, quantity and inspection requirements so the engineering team can evaluate manufacturability and the applicable process.


24. How MFG SOLUTION Approaches Heat-Treated CNC Parts

MFG SOLUTION does not treat heat treatment as an isolated operation.

The engineering team can evaluate the complete route:

Material → CNC machining → Heat treatment → Finish machining → Surface treatment → Inspection

The actual sequence is adjusted according to:

  • Material
  • Geometry
  • Quantity
  • Tolerance
  • Hardness
  • Surface requirements
  • Inspection requirements

For 17-4PH, for example, machining and aging treatment need to be coordinated around the selected material condition.

For alloy steel components, the appropriate heat-treatment strategy may instead involve quenching, tempering or case hardening.

For stainless steels such as 316, conventional hardening heat treatment may not be appropriate at all.

The engineering requirement determines the process.


25. Heat Treatment Checklist for Precision CNC Parts

Before releasing a heat-treated component to production, review:

Material

  • Exact grade?
  • Condition?
  • Material certificate?
  • Traceability requirement?

Heat treatment

  • Treatment type?
  • Hardness requirement?
  • Case depth?
  • Applicable standard?
  • Heat-treatment certificate?

Machining

  • Rough machining?
  • Finish machining?
  • Machining allowance?
  • Critical dimensions?

Geometry

  • Thin walls?
  • Long sections?
  • Uneven thickness?
  • Deep pockets?
  • Symmetry?

Finishing

  • Anodizing?
  • Plating?
  • Passivation?
  • Polishing?
  • Electropolishing?

Quality

  • Hardness testing?
  • CMM?
  • Dimensional report?
  • Surface roughness?
  • FAI?
  • Traceability?

This checklist can help engineering and purchasing teams prevent avoidable production problems.


FAQ: Heat Treatment and CNC Machining

1. Should heat treatment be performed before or after CNC machining?

It depends on the material, geometry and tolerance. A common strategy is rough machining, heat treatment and then finish machining so dimensional changes can be corrected.

2. Does heat treatment always cause dimensional distortion?

No. The amount of dimensional change depends on material, treatment, geometry, fixturing and process control. Some components experience very little movement, while others require significant process planning.

3. Why is machining allowance needed?

Allowance provides additional material that can be removed after heat treatment to establish final dimensions.

4. Can stainless steel be heat treated?

It depends on the stainless-steel grade. 304 and 316 are not conventionally hardened by quenching, while precipitation-hardening grades such as 17-4PH can be strengthened through appropriate heat treatment.

5. Can CNC machining be performed after hardening?

Yes. The exact machining method depends on the final hardness and dimensional requirements. Some hardened components may require grinding or specialized cutting tools.

6. What is the difference between heat treatment and surface treatment?

Heat treatment primarily changes material properties and structure. Surface treatment modifies surface characteristics such as corrosion resistance, appearance, wear resistance or surface condition.

7. Does heat treatment increase manufacturing cost?

Usually it adds an additional process and may require post-treatment machining or inspection. However, it can be essential for achieving the required performance and service life.

8. What information should I provide for a heat-treated CNC quotation?

Provide the material grade, heat-treatment requirement, hardness, drawing, 3D CAD model, quantity, tolerances, surface finish, inspection requirements and documentation requirements.


Conclusion

Heat treatment should be considered part of the complete CNC manufacturing strategy rather than an isolated operation.

For precision metal parts, the relationship between:

Material → Machining → Heat Treatment → Finish Machining → Surface Treatment → Inspection

can determine whether the final component meets its dimensional and functional requirements.

The correct approach depends on the material and application.

Alloy steels may require quenching and tempering.

Case-hardening steels may require carburizing.

Selected components may benefit from nitriding.

17-4PH stainless steel can use precipitation-hardening treatments.

304 and 316 stainless steels require a different approach because they are not conventionally hardened through quench-and-temper treatment.

The key is to define the required engineering result first and then build the manufacturing process around it.

For precision components with demanding tolerances, early process planning can help control distortion, machining allowance, inspection requirements and overall production cost.


Start Your Heat-Treated CNC Project

If you have a precision metal component that requires heat treatment, send MFG SOLUTION the engineering package for review.

Please provide:

  • 2D drawing
  • 3D CAD model
  • Material grade
  • Heat-treatment requirement
  • Quantity
  • Critical tolerances
  • Surface treatment
  • Inspection requirements

The engineering team can evaluate the machining sequence, heat-treatment route, finishing requirements and inspection scope.

Get an Engineering Review and Quotation:

Contact MFG SOLUTION:

https://mfg-solution.com/contact

WhatsApp
MFG SOLUTIONWhatsApp enquiries

Have a manufacturing project?
Tell us about your parts, materials and requirements.

+86 181 2296 9278

Start WhatsApp chat ↗Opens WhatsApp. Send your message there.