"Gazprom did not and does not plan to buy a 20% share in the Repsol company. All talk of this is based on the fact that they want to sell this stake - but that does not mean anyone wants to buy it," company spokesman Sergei Kupriyanov said.
Repsol is one of the world's 10 largest private oil and gas companies, selling about 55 million metric tons (403 million barrels) of oil and 32 billion cubic meters of natural gas annually.
Earlier this week, Russian Deputy Prime Minister Alexander Zhukov said during his visit to Spain that "Gazprom is studying the issue of buying a 20% stake in Repsol offered for sale by the Spanish construction company Sacyr Vallehermoso."
Soon after the announcement on Wednesday, shares in Repsol and Sacyr rose 0.14% and 5.3%, respectively.
Spanish Prime Minister Jose Luis Rodriguez Zapatero said in an interview with Cadena SER radio that neither Gazprom nor Repsol had any plans for such a deal.
Sacyr Vallehermoso, Repsol's main shareholder, confirmed on Thursday that it was holding talks "with interested investors" on the purchase.
The Mundo newspaper reported that Sacyr was in talks with Russia's largest independent crude producer LUKoil on selling the stake.