Traditionally the Spanish Corporate and Securities Law did not devote much attention to corporate governance issues. This situation started to change after the publication of different corporate governance codes since the year 1997. Although the recommendations of these codes did not have mandatory character, some of them have been incorporated in the mandatory law by the legislator through different instruments. The main objective of this paper is to examine these mechanisms and the purpose of the legislator with each one. The analysis shows that in Spain, the corporate governance recommendations have had a very important role in the creation of corporate governance mandatory rules.