(Adds comment from official in Tehran, background, byline)
By Fredrik Dahl
VIENNA, May 2 (Reuters) - Iran is optimistic about progress in talks with world powers over its nuclear programme but it will never give up its right to the peaceful use of atomic energy, a senior Iranian official said on Wednesday.
Tehran reopened negotiations with six world powers over its uranium enrichment programme last month and they have agreed to meet again in Baghdad on May 23.
"We continue to be optimistic about upcoming negotiations," Deputy Foreign Minister Mohammad Mahdi Akhondzadehhe said in a speech to a nuclear non-proliferation conference in Vienna.
But he added: "There should be no doubt that the great nation of Iran...will never abandon exercising its inalienable right to peaceful use of nuclear energy and technology,"
The United States and its allies say Iran's nuclear program is a cover for developing atomic weapons, a charge Tehran denies.
They have imposed new sanctions against Iran's energy and banking sectors since the beginning of this year and the European Union is set to impose a total embargo on the purchase of Iranian crude oil in July.
The talks with the United States, Russia, China, Germany, France and Britain resumed last month in Istanbul after more than a year - a chance for the powers and Iran to halt a deterioration in diplomacy and help avert the threat of a new Middle East war.
Separately in Tehran, an adviser to Iran's supreme authority Ayatollah Ali Khamenei said the Baghdad talks should lead to the lifting of sanctions, according to Iranian media.
The comments reflect increasing emphasis in the Islamic state that an end to sanctions is vital to the talk's success.
It was also the first time an influential political figure explicitly said he expects progress on the issue in Baghdad.
"At the least, our expectation is the lifting of sanctions," Gholam-Ali Haddad Adel said in answer to a question.
Western governments have credited the sanctions against Iran's financial institutions as instrumental in forcing Tehran back to the negotiating table.
European diplomats have said an EU oil embargo is a valuable tool and is unlikely to be lifted unless tangible progress is made at the meeting.
"I hope the Baghdad negotiations complete the talks that took place in Istanbul and the other side should take note that it should use rational behaviour with Iran and country will never surrender to pressure," Fars news agency quoted Haddad Adel as saying. (Additional reporting by Marcus George in Dubai; Writing by Alessandra Rizzo; Editing by Angus MacSwan)