We propose a simple nondestructive method to obtain refractive-index profiles of a graded-index (GRIN) light-focusing rod by means of a diffraction grating. In our proposed method, a laser beam is illuminated through a diffraction grating perpendicular to the axis of the GRIN lens and the separation between the zeroth and first-order diffraction peaks is measured and analyzed. The results demonstrate that the refractive-index profiles of commercially available GRIN lenses can be successfully reconstructed.