This paper proposes stochastic model predictive control as a tool for hedging derivative contracts (such as plain vanilla and exotic options) in the presence of transaction costs. The methodology combines stochastic scenario generation for the prediction of asset prices at the next rebalancing interval with the minimization of a stochastic measure of the predicted hedging error. We consider 3 different measures to minimize in order to optimally rebalance the replicating portfolio: a trade-off between variance and expected value of hedging error, conditional value at risk, and the largest predicted hedging error. The resulting optimization problems require solving at each trading instant a quadratic program, a linear program, and a (smaller-scale) linear program, respectively. These can be combined with 3 different scenario generation schemes: the lognormal stock model with parameters recursively identified from data, an identification method based on support vector regression, and a simpler scheme based on perturbation noise. The hedging performance obtained by the proposed stochastic model predictive control strategies is illustrated on real-world data drawn from the NASDAQ-100 composite, evaluated for a European call and a barrier option, and compared with delta hedging.