The purpose of a spoiler is to improve the grip and road holding of a car. The airflow of the car changes with increasing speed. By applying a spoiler, the downforce and thus the road holding can be improved. Spoilers can be mounted on either the front or rear of a car.
In fact, a spoiler only makes sense at high speeds (above 120km/h). It is of no use on the normal Dutch road surface. Spoilers are often only mounted to improve the appearance of a car.