Developing methodology for computing accurate forecasts of electricity prices in liberalised markets is necessary to improve the bids submitted to the market operator by both consumers and producers to maximise their benefits and utilities, respectively. Here, we propose the extraction of common factors from the 24-dimensional vector of prices, and using them for one-day-ahead forecasting. This methodology is based on the Peña-Box (1987) and Lee-Carter (1992) models and is able to take into account the multivariate structure of the data. The data selected to illustrate the proposed methodology are those from the Iberian Market in the period January 2007 to January 2009, and numerical results in terms of prediction accuracy have also been compared with those by Garcĩa-Martos et al. (2007), obtaining a statistically significant improvement. For the whole period used to test the out-of-sample forecasting accuracy the authors have computed a forecast for every hour and the average MAPE is 7.39%. Furthermore, a very important feature of the proposed methodology, the Dynamic Factor Model (DFM) is that is a powerful tool for mid- and long-term forecasting. This is an important difference between DFM and other methodologies for which the accuracy dramatically degrades when increasing the forecasting horizon.