International Friendly: El Salvador 1 Ivory Coast 2
Experienced forwards Gervinho and Didier Drogba combined for the Africans' two goals at Toyota Stadium in Dallas, Texas, as Ivory Coast coach Sabri Lamouchi selected close to his strongest team.
Drogba set up Gervinho in the eighth minute, while the latter returned the favour three minutes before half-time, as Ivory Coast's captain scored his third goal in as many games for his country.
El Salvador ensured a nervous finish for Lamouchi's men, after Arturo Alvarez converted a penalty with 15 minutes left but Ivory Coast held on for their first win in four matches.
Having watched Ivory Coast lose 2-1 to Bosnia and Herzegovina on Friday, Lamouchi made eight changes to his starting line-up against El Salvador.
Kolo Toure, who has been struggling with malaria, came into central defence, while Serge Aurier and Arthur Boka were also drafted into Lamouchi's back four and Boubacar Barry started in goal.
Geoffrey Serey Die slotted into midfield, while Lamouchi completely changed his front three with Didier Drogba, Gervinho and Salomon Kalou returning.
Those changes seemed to make an immediate effect with Drogba picking out Gervinho's diagonal run in the eighth minute and the Roma forward took the ball around El Salvador goalkeeper Derby Carrillo and slotted home from a tight angle.
But Ivory Coast only managed four more efforts on goal in the first half in a rather lacklustre performance with the African side only doubling their advantage in the 42nd minute when Drogba volleyed Gervinho's cross into the net.
Drogba's goal was the 36-year-old's seventh in nine games for Ivory Coast, again underlining his importance to his country's hopes in Brazil.
Just before the hour mark, Ivory Coast should have put the game to bed but Souleymane Bamba headed over from close range from Kalou's cross.
El Salvador started to build some momentum as the second half wore on and got on the scoreboard in the 75th minute after Toure was judged to have fouled Jonathan Aguilar in the penalty area, with Alvarez making no mistake from the spot.
Ivory Coast will face Japan in their opening game of the World Cup on June 14, before taking on Colombia and Greece in Group C.