Morgan will lead the side for the tri-series in Australia after Christmas and then the World Cup in Australia and New Zealand in February and March. Cook, will not be going to the World Cup, the ECB said.
An ECB statement read, "ECB today (Saturday) announced that Eoin Morgan has replaced Alastair Cook as England one-day captain with immediate effect.
"England selectors met yesterday (Friday) to pick a 15-man one-day squad for the tour to Australia and the ICC Cricket World Cup. Selectors recommended to managing director England cricket Paul Downton a change in captaincy which has now been approved by the ECB chairman.
"Cook will continue as England Test captain." After England's series-ending defeat in Colombo on Tuesday, Cook, who hasn't scored a one-day century since June 2012, conceded he could have no complaints if he lost the one-day captaincy.
But the decision to remove him from the role with the World Cup looming is still a major reversal by Downton and head coach Peter Moores, who have given Cook absolute backing this year.
Cook, who turns 30 on Thursday, said: "I am gutted to be left out of the World Cup squad, and it is likely to take me a while to get over the disappointment.
"That said I wish Peter, Eoin and the lads all the best for the World Cup. I would also like to thank all the players and fans who have supported me during my time as one-day captain." Morgan described being handed the England World Cup captaincy as "a huge honour".
The 28-year-old Irishman added: "I firmly believe that with the players currently involved in the one-day set-up we have the makings of a very good one-day side, a young side that can surprise people at the World Cup."
Downton said he had "complete confidence" in the decision made by the selectors.
He said, "Having spent time with Alastair yesterday (Friday), he accepts that it has been made in the best interests of the one-day side. "Eoin has held a senior role in our limited-overs teams for some time and has impressed on the occasions he has led the side."
Downton added, "Alastair remains an integral part of England cricket and continues to have a vital role in developing our emerging Test side.
"I would like to thank him for his leadership of the one-day side since 2011, a period which saw the team reach number one in the world, Alastair lead the team to more wins than any previous England captain and also make the final of the ICC Champions Trophy.
"Alastair will now focus on an exciting and challenging year of Test cricket beginning with a series against West Indies followed by an Ashes summer culminating in a series against South Africa next winter."
Whitaker expanded on the reasoning behind appointing Morgan, who has also been in a trough of form with the bat, with just one half-century in his last 19 innings.
Whitaker said "We spent a considerable time yesterday discussing the make-up of a squad that gives England the best possible chance of success at the World Cup, which begins in less than two months.
"Having reviewed the recent series against Sri Lanka we came to the conclusion that there was no place for Alastair Cook amongst our strongest 15 one-day players and therefore recommended Eoin Morgan be appointed one-day captain."
Cook led England in six of their seven matches in Sri Lanka, where they lost 5-2 and he made just 119 runs at 19.83.
Morgan made 90 at 12.85. He was also in charge in the other fixture, a defeat for which Cook was banned because of an over-rate offence.