The two leaders held their first face-to-face meeting in a year in the Russian Black Sea resort of Sochi where they also discussed the conflicts in Syria and Ukraine and the Iran nuclear deal.
The pair showed a united front on the construction of the pipeline linking the two countries via the Baltic Sea, a project several EU countries oppose.
The Wall Street Journal reported on Friday that the US administration has increased pressure on Europe to abandon the deal in exchange for avoiding a trade war.
The Nord Stream 2 pipeline would call further into question Ukraine's role as a key transit nation for Russian gas to Europe, but Putin sought to reassure shipments would continue in any case.
“We will continue gas shipments (via Ukraine) as long as they are economically justified,” Putin said during a press conference with Merkel.
For her part, Merkel said that “Germany believes Ukraine's role as a transit country should continue after the construction of Nord Stream 2… it has a strategic importance”. She added that Germany was ready to help ensure such an outcome.
Germany has supported plans by Russia's Gazprom to build Nord Stream 2, for which preparatory works have begun and should be completed in 2019.
Iran nuclear deal
Putin and Merkel also discussed the Iranian nuclear deal following US President Donald Trump's decision to withdraw from the historic 2015 agreement.
“Germany, Britain, France and all our EU colleagues support this deal and will continue to support it,” Merkel said.
“The deal is not perfect, but it is better than a lack of a deal. It guarantees more control and more security,” she added.
As part of the deal, Tehran agreed to curb its nuclear programme in exchange for the lifting of some international sanctions.
The Europeans now want to avoid at all costs Tehran abandoning the deal and relaunching its programme to acquire a nuclear weapon. They also want to protect their economic interests in Iran, threatened by Washington's reintroduction of sanctions.
Merkel said the European Union is “currently discussing” a law that would block US sanctions on European companies wanting to invest in Iran.
The Kremlin has in recent days increased its diplomatic efforts to try to maintain the agreement it described as “crucial for regional stability and for the stability of the entire world”.
Syria and Ukraine
The fallout over the Iran deal is a rare topic for rapprochement between Europe and Moscow, whose relations are marred by disagreements over the Syria conflict, Moscow's 2014 annexation of Crimea and the subsequent war in eastern Ukraine.
These tensions have only worsened in recent months following the poisoning of former Russian spy Sergei Skripal in Britain that led to an unprecedented wave of expulsions of Russian diplomats from Western countries. On Friday Putin wished Skripal “good health” after he was discharged from a British hospital following his poisoning in March.
The two leaders also pledged to relaunch the political peace process in Syria, where Russia has intervened militarily to support President Bashar al-Assad's regime. On the eve of Merkel's visit, Putin had hosted Assad in a rare meeting in his Sochi residence.
The pair also discussed the conflict in eastern Ukraine, which has seen an uptick in fighting this week.
Berlin and Moscow, along with Paris, signed peace agreements in Minsk in 2015 that aimed to put an end to a conflict that has left more than 10,000 dead since it began in April 2014.
Putin on Friday said no date has been set for the leaders of the four countries to meet. He added that there is “no alternative” to the Minsk agreement to regulate the conflict.
The last summit between the four countries, known as the Normandy Quartet, was held in October 2016 and was inconclusive.
Putin is due to meet with French President Emmanuel Macron next week.