In a possible sign of division within the opposition alliance, Mr Odinga's vice presidential candidate and a number of other senior leaders were absent from the ceremony.
The move sets east Africa's richest country on a unsafe path towards a constitutional crisis at best, and at worst a repeat of the election violence that left over a thousand dead in 2007.
Authorities appear to have opted for a media blackout of the event rather than deploy police to stop or disperse the meeting. "You can feel it in the air", opposition lawmaker Gladys Wanga told the crowd at Uhuru Park earlier in the day. They flooded into a central park even after the government threatened to disperse any demonstrations.
"I, Raila Omolo Odinga, do swear that I will protect the nation as people's president, so help me God", Mr. Odinga, who held a bible, said to the cheers of more than 15,000 people in Uhuru Park, next to Nairobi's main business district. We did not expect this will come to our country.
"If in this country we ever relied on the benevolence of the police, we would not have achieved anything democratically", Magaya said.
The announcement by the National Super Alliance (NASA) sets the stage for another round of election-related clashes between police and opposition supporters and raises fears of more civilian deaths, AP reported.
The U.S. State Department congratulated Kenyatta and Deputy President William Ruto on their victory after the October election was allowed to stand, but expressed deep concern about "ongoing political tensions in Kenya" and urged security forces to "refrain from the use of unnecessary force against citizens exercising their democratic rights".
In Kenya, independent local broadcasters say the government orchestrated a media blackout Tuesday to prevent live TV coverage of opposition leader Raila Odinga swearing himself in as the so-called "people's president". Odinga did not run in the second election, claiming voting irregularities, but has since spurred large swells of support. It also said it ruled against Kenyatta because the commission refused to open its computer system for court scrutiny to dispel Odinga's claims.
The incident comes as a government shutdown of Kenya's top three TV stations continues after they showed the mock inauguration of opposition leader Raila Odinga as "the people's president". The commission said the information was fake, and said the opposition was misleading the public "on the results pathway, the servers, information on the public portal and the forms used to declare results".
Matiangi said Odinga's swearing-in itself was also under investigation and that 'appropriate legal action would be taken.