Hungary's prime minister says his country has reached a "political agreement" with Moscow on a new gas deal, Hungary's main aim in hosting Russian President Vladimir Putin.

Prime Minister Viktor Orban said Tuesday after his meeting with Putin that only "technical" details needed to be finalized on the deal which will replace a 20-year contract expiring in December.

Orban said "Hungary needs Russia" and it was important for Russia to be open to Hungarian products, which have been affected by Russia's ban on EU imports — a countermeasure to EU sanctions against Russia because of the Ukraine crisis.

Orban visited Putin last January when they agreed for Russia to expand Hungary's sole nuclear power plant while providing 10 billion euros ($11.4 billion) to help cover construction costs.