Soldiers have killed Guinea-Bissau's President João Bernardo 'Nino' Vieira, hours after the tiny West African state's army chief was killed in an attack.

Gunfire and the sound of heavier weapons later resounded in Bissau city and it remains unclear who is in control.

Security sources, who declined to be identified, said Mr Vieirawas killed as he was leaving his home this morning.

Sandji Fati, a close associate of the president, said diplomats from the Angolan embassy had come to take him and his wife to safety, but he refused to leave his house. Mr Fati says Mrs Vieira is now at the Angolan embassy.

The country of just 1.6m people, a former Portuguese colony, has suffered years of coups and civil strife and has been used in the past few years as a conduit for smuggling Latin American cocaine to Europe.

Road to Power

Mr Vieira seized power in a coup in 1980 after fighting as a guerrilla commander in the civil war that led to independence from Portugal in 1974.

The 69-year-old took Guinea-Bissau away from socialism and opened up the economy, but his country was accused of human rights abuses under his rule.

He won Guinea-Bissau's first multi-party elections in 1994 but was ousted in a putsch in 1999 after a civil war. He returned from asylum in 2005 to win a presidential election, the result of which was disputed.

The president had been at odds with armed forces chief of staff General Batista Tagme Na Wai, who was killed in an attack yesterday evening.

Mr Vieira also quarrelled with the largest political party, the PAIGC, which defeated a new formation allied to the president in a parliamentary election last November. Soon afterwards, he survived an attack by renegade soldiers.

He hails from the Pepel ethnic group, one of Guinea-Bissau's smaller tribes from a coastal region in the northwest. There was often mistrust between Mr Vieira and Guinea-Bissau's biggest ethnic group, the Balante, to which General Na Wai belonged.

A security source said soldiers from the Balante ethnic group led the attack on Mr Vieira and looted his home afterwards.

'Tagme always said that his and the president's fate were linked and if he died, so would the president,' the source said.

Analysts say political instability has been exacerbated in the past few years as Latin American drugs gangs have taken advantage of Guinea-Bissau's poorly policed coastline and remote airstrips to smuggle cocaine through Africa to Europe.

They say well-resourced drug cartels with access to weapons, speedboats and planes have been able to secure cooperation from senior officials in the armed forces and government in one of the world's poorest countries, whose main export is cashew nuts.