Pope Francis and Iranian President Hassan Rouhani at the Vatican before talks on Tuesday. (Andrew Medichini/AFP/Getty Images)

Iran’s president asked Pope Francis for his prayers Tuesday, and the pontiff bestowed a medal depicting an early Christian saint, in a Vatican encounter rich with spiritual symbolism but also touching on Middle East conflicts and terrorism fears.

The 40-minute meeting — the first between an Iranian president and a pope since 1999 — was something of a sideline to the wider objectives of President Hassan Rouhani’s four-day European trip, which began Monday.

Rouhani and his 120-member entourage seek mostly to drum up foreign investment from Italy and France after the lifting of international sanctions under a nuclear accord with world powers.

But Rouhani also used his talks with Francis to bolster his personal image as a moderate comfortable in dealing with the West. In addition, Rouhani did not miss a chance to strengthen his calls for Iran to play a bigger role in Middle East affairs, including bids to reach a political accord in war-battered Syria.

Iran is a critical ally of Syrian President Bashar al-Assad, whose envoys are scheduled to take part in U.N.-backed peace talks that could begin later this week in Geneva. Francis, meanwhile, has frequently denounced the ongoing bloodshed in Syria and the increasing pressures and persecution facing Christians across the region.

“I ask you to pray for me,” Rouhani said to the pope after their private meeting. He presented Francis with a carpet — about 3-by-4 feet — made in the seminary city of Qom, the center of Shiite Muslim scholarship in Iran.

Francis, in turn, gave Rouhani a medal depicting a famous act by the 4th century Saint Martin: giving part of his coat to a cold beggar — a gesture Francis called “a sign of unsolicited brotherhood.”

Rouhani’s predecessor, Mahmoud Ahmadinejad, did not make a visit to the Holy See, which had joined in denunciations of his combative comments, including warnings against Israel.

In 1999, Iran’s reformist president, Mohammad Khatami, held talks with Pope John Paul II, and the Vatican later endorsed Khatami’s calls for greater dialogue between faiths and societies. Khatami also was among the world leaders at John Paul’s funeral in 2005.

In a statement, the Vatican appeared to reward Rouhani by noting that the talks included “the important role that Iran was called to play” to combat terrorism.

Iran has insisted it shares the goals of the West and its allies to defeat the Islamic State and other groups. But the United States and others remain deeply uneasy over Tehran’s backing for Assad and its aid to anti-Israel factions such as Lebanon’s Hezbollah.

Iran was also urged to help fight arms trafficking, the Vatican said.

Francis, a native of Argentina and the first pope from the Americas, had a pivotal role in helping start talks between the United States and Cuba, former Cold War foes that resumed diplomatic ties last year.

The Vatican has welcomed the nuclear accord, but there is little sign of further rapprochement between Washington and Tehran amid strong resistance from political factions on both sides.

Earlier, Rouhani tried to link the battle against militants with his pitch for foreign investment.

“If we want to combat extremism in the world, if we want to fight terror, one of the roads before us is providing growth and jobs. Lack of growth creates forces for terrorism. Unemployment creates soldiers for terrorists,” said Rouhani, whose planned trip to Europe in November was postponed because of the Paris terrorist rampage that claimed 130 lives.

Already, Rouhani will return home with an array of deals from Europeans eager to return to the huge Iranian consumer market.

On Monday, Italy announced more than $18 million in contracts including steel exports and road and rail work. In France, Rouhani’s next and last stop, he hopes to court French automakers, which had a major presence in Iran before sanctions and seek to return.

Iran also has opened talks with airline manufacturer Airbus for planes to replace the country’s aging passenger fleet, which includes some Boeing planes made before the 1979 Islamic revolution.

Some Italians, meanwhile, were appalled after authorities covered up nude statues, including the Roman goddess Venus, at the Capitoline Museums for a visit by Rouhani and others.

“Respect for other cultures cannot, and must not, equal the denial of our own,” said Luca Squeri, a parliament member with former premier Silvio Berlusconi’s Forza Italia party, according to Italy’s state-run Ansa news agency.

Read more:

Key moments in U.S.-Iran tensions

Today's coverage from Post correspondents around the world