An optimal control problem governed by an unilateral obstacle problem is considered. The problem is discretzed by using linear finite elements for the state and the obstacle and a variational discrete approach for the control. Based on strong stationarity and a quadratic growth condition we establish a priori error estimates which turn out to be quasi-optimal under additional assumptions on the data. The theoretical findings are illustrated by two numerical tests.