A device (6, 7, 8, 9, 10) for attenuating pressure oscillations in a hydraulic line (4) between a pressure source (2) and a consumer (3), comprising a sensor (6) for sensing pressure oscillations in the hydraulic line (4), and an actuator connected to the hydraulic line (4) a control apparatus (10) capable of evaluating the pressure oscillations (11) detected the sensor (6) in the hydraulic line (4) and activating said actuator (7) said actuator (7) comprising a piezoelement (19) energized by the control apparatus (10) depending on parameters of the pressure source (2) in such a way that the actuator (7) generates pressure oscillations (13) in the hydraulic line (4) which are at least approximately in antiphase to the pressure oscillations (11) detected by the sensor (6), a transmission element (23) arranged between the piezoelement (19) and a membrane (17) which is acted on one side by hydraulic fluid (22) present in the hydraulic line (4), with which the amplitude (14) of an oscillation (13) of the piezoelement (19) can be amplified, said actuator (7) comprising a housing (15, 16) which is connected non-positively to the hydraulic line (4) and in which the piezoelement is supported and said piezoelement (19) having one side operatively connected to one side (21) of the membrane (17), and another side acted on by the hydraulic fluid (22) in the hydraulic line (4).