German Chancellor Angela Merkel has pledged further economic support for Myanmar if it holds fair elections next year and does more to protect ethnic minorities.

After talks with Myanmar's President Thein Sein in Berlin on Wednesday, Merkel said that Germany was ready to boost investment and development aid, but would keep a close eye on human rights in the country.

"Myanmar is a country with many ethnic groups and for economic growth, peace is of course required, and peace requires compromise and tolerance with regard to minorities," she said.

Myanmar, one of Asia's poorest countries, has a by-election late this year and a parliamentary election in 2015.

Merkel hailed "democratic progress" in the nation, notably in the area of press freedom, but said Berlin was watching preparations for the polls.

"We expressed our hope that the elections will be free, fair and transparent," she said of her talks with Thein Sein, a former general whose quasi-civilian regime is now pursuing reforms.

Merkel said Germany was focusing aid for Myanmar on an overhaul of its educational system and assistance to small- and medium-sized companies "in regions where there are ethnic conflicts".

Rohingya issue

Thein Sein, whose government has been accused of failing to stem two years of sporadic anti-Muslim violence, remarked he was the first president of Myanmar to visit Germany in three decades.

Sein noted that his country had only been on a path to democracy for three years.

"In this time we had a lot of difficulties," he said, but were able to pursue reforms "without bloodshed".

The president said he would support opposition calls to amend Myanmar's constitution before the elections if they received the backing of parliament and voters in a referendum.

Deadly clashes in Rakhine two years ago have left about 140,000 people, mainly Rohingya Muslims, trapped in miserable displacement camps with scant access to basic services and work.

Violence has since erupted periodically across the country, most recently in the second largest city of Mandalay.

Activists have also accused the government of backsliding on press reforms with the introduction of vague media laws and the prosecution of several local journalists.