Nigeria's main opposition party, the ANPP, has said it will join the new government of President Umaru Yar'Adua.
Election observers had said Umaru Yar'Adua's victory was not credible
The deal comes after days of talks called by the president, whose April election victory was judged "not credible" by international observers.
Both parties have agreed to work to address issues including the electoral process and the constitution.
The All Nigeria People's Party said in a statement it "accepts to participate in the Yar'Adua administration".
The announcement came after the rival parties held two days of talks.
The ANPP has filed dozens of petitions contesting the result of April's elections.
But Mr Yar'Adua has said he wants to address Nigeria's pressing problems - including poverty, unrest in the oil-rich Niger Delta region and violent crime.
Mr Yar'Adua received 24.6 million votes in the election compared with some 6.6 million for the ANPP candidate, Muhammadu Buhari.
The BBC's Senan Murray in Abuja says the development has left the ANPP divided as Mr Buhari has distanced himself from the decision.
Mr Buhari says accepting President Yar'Adua's offer is premature.