A device for regulating the pressure of a pump has a piston which is forced down and can be adjusted with respect to the compressive force in such a way that the forward-running head of the piston closes an opening which is arranged on a valve seat assigned to the overflow opening.