The influence of shot peening on microstructure of laser hardened 17-4PH was investigated by using X-ray diffraction profiles. The domain size, microstrain and dislocation in different depths were calculated via Voigt method and dislocation density calculation method according to Williamson's work. Two typical materials in laser hardened 17-4PH (matrix material and laser hardened material) and three families of crystalline planes ({1 1 0}, {2 00}, {2 1 1}) were chosen as research objects. Microstructural results from XRD investigation quantified the shot peening influence on microstrain, domain size and dislocation density in microstructure changed layer in these three plane diffraction directions. Results showed that shot peening was an efficient cold working method to alter microstructure in near surface region and microstructure strengthening mechanism of shot peening played an important role on improving the surface mechanical properties. In microstructure changed layer, the domain size increased and microstrain as well as dislocation density decreased with depth increasing, which led to the mechanical properties decrease with depth increasing. With increasing peening intensity from 0.2 mmA + 0.1 mmA to 0.5 mmA + 0.1 mmA, the depth of microstructure changed layer increased but the surface microstructure did not change, no matter in matrix material or laser hardened material. As laser hardened material had a stronger resistance against shot peening influence on microstructure, the depth of microstructure changed layer in matrix material was larger than that in laser hardened material when same peening intensity was carried out on these two materials. The variation of domain size, microstrain and dislocation density in depth in {1 1 0}, {2 0 0} and {2 1 1} diffraction directions represented shot peening could alter material microstructure in all plane diffraction directions in microstructure changed layer. (C) 2011 Elsevier B.V. All rights reserved.