We provide a general framework in which to determine the optimal penalty fee inducing the contractor to respect the contracted delivery date in public procurement contracts (PPCs). We do this by developing a real option model that enables us to investigate the contractor’s value of investment timing flexibility which the penalty rule – de facto – introduces. We then apply this setting in order to evaluate the range of penalty fees in the Italian legislation on PPCs. According to our calibration analysis, there is no evidence that the substantial delays recorded in the execution times of Italian PPCs are due to incorrectly set penalty fees. This result opens the way for other explanations of delays in Italian PPCs: specifically, we extend our model to investigate the probability of enforcing a penalty which we assume negatively affected by the "quality" of the judicial system and the discretionality of the court in voiding the rule. Our simulations show that the penalty fee is highly sensitive to the "quality" of the judicial system. Specifically referring to the Italian case, we show that the optimal penalty should be higher than those set according to the present Italian law.