Topological nodal-line semimetals attract growing research attention in the photonic and optoelectronic fields due to their unique topological energy-level bands and fascinating nonlinear optical responses. Here, to the best of our knowledge, we first report the saturable absorption property of topological nodal-line semimetal HfGeTe and the related pulse modulation in passively Q-switched visible lasers. Few-layer HfGeTe demonstrates outstanding saturable absorption properties in the visible-light band, yielding the saturation intensities of 7.88, 12.66, and 6.64 μJ/cm 2 at 515, 640, and 720 nm, respectively. Based on an as-prepared few-layer HfGeTe optical switch and a Pr:LiYF 4 gain medium, Q-switched visible lasers are also successfully achieved at 522, 640, and 720 nm. The minimum pulse widths of the green, red, and deep-red pulsed lasers are 150, 125.5, and 420 ns, respectively. Especially for the green and red pulsed laser, the obtained pulse width is smaller than those of the low-dimensional layered materials. Our work sheds light on the application potential of topological nodal-line semimetals in the generation of visible pulsed lasers.