Abstract Electricity markets have suffered important modifications in recent decades in many countries, in which a competition framework has been established with the aim of improving market efficiency and reducing energy prices. However, this new paradigm does not assure optimal solutions, as new constraints can be introduced in optimization processes that can affect the resulting prices. An example of this situation is the establishment of power purchase agreements between producers and consumers. A wide literature can be found regarding electricity markets. Some of this literature refers to the theory of spot prices and its application to them. This paper deals with the obtaining, decomposition and deduction of behavior rules of spot prices, and their influence on established contractual relationships in a deregulated market environment which allows power purchase agreements between consumers and producers. It is performed by a deterministic modeling of the complete generation-grid system. The influence of the existence of this kind of agreements on both total costs and spot prices is discussed.