Kumba Yala, deposed president of Guinea-Bissau, renounced his post on Wednesday in the capital Bissau, media reports said.
Yala announced his resignation in a speech at his heavily guarded home in Bissau, saying, "I relinquish power."
He called on the army to return to their barracks and said a new government composed only of civilians should be named.
The agreement for Yala, whom the army toppled in a bloodless coup Sunday, to renounce the presidency in an address to the nation was a compromise that would ease international recognition of Bissau's new regime, Bissau military sources said earlier Wednesday.
The compromise was reached between the country's new military rulers, a commission sent to Bissau by the Economic Community of West African States (ECOWAS) and Yala, who is under house arrest in the capital.
While details of the agreement were not made public, the sources said it broke a two-day impasse between the military juntaand ECOWAS, who have held repeated meetings in Bissau since Monday.
The Catholic archbishop of Bissau, Jose Camnate, who heads a junta-appointed committee to help set up a caretaker civilian government, said early Wednesday that the military had insisted onthe "irreversibility" of the coup, while ECOWAS had refused to accept the army's justifications for seizing power.
Overnight Tuesday, the sources said, the junta, ECOWAS and Yalareached an understanding on the president's renunciation and how he would present it over television.
Guinea-Bissau army chief of staff General Verissimo Correia Seabra, who led the coup and has proclaimed himself "interim president," has promised elections and set in motion a process to choose a caretaker civilian cabinet.