The Sochi Winter Olympics were officially declared open by Russian President Vladimir Putin on Friday evening.
The Games has cost an estimated $50 billion to stage, and the build-up has been marred by political controversies and security threats.
But the opening ceremony was a spectacular affair, with the centre-piece the Russian president announcing: "I declare the Olympic Games open."
There was an early glitch when one of five illuminated snowflakes that were to morph into the five Olympic rings inside the arena failed to open.
The athletes emerged up a ramp from beneath the stage to the applause of a packed arena and a giant satellite image of each nation taken from space was projected onto the floor.
Soviet-era sports legends Irina Rodnina and Vladislav Tretyak jointly lit the Olympic flame.
Just as in London 2012, the identity of who would light the flame had been kept a closely-guarded secret.
Rodnina was a 10-time world and three-time Olympic figure skating champion and Tretyak was goaltender of the legendary Red Machine ice hockey team which won Olympic gold in 1972, 1976 and 1984.
Ballet stars, acrobats, astronauts and ex-heavyweight boxer Nikolai Valuev were all involved in a stunning ceremony.
The theme of the event was "Dreams of Russia", with a young girl named Lyubov (love) guiding spectators at the packed Fisht stadium on the Black Sea coast through thousands of years of Russian history.
Ballet stars brought to life Leo Tolstoy's epic novel 'War and Peace', performing in an elaborate imperial ball.
A giant chugging steam train entered the stadium suspended from the gantry as the story moved on to the events of the Russian Revolution of 1917.
Valuev played Uncle Styopa, the policeman character from a series of Soviet children's poems as the story reached the mid-20th century.
To the strains of Tchaikovsky's "Swan Lake", dancers clad in white - including the world famous ballerina Diana Vishneva - swirled around the stadium floor, eventually creating the shape of a dove before opera star Anna Netrebko sang the Olympic Hymn.
Tennis star Maria Sharapova - who spent part of her child in Sochi - carried the torch into the stadium and handed it over to Olympic pole vaulter Yelena Isinbayeva. Alina Kabaeva was then given the torch and that immediately had the whole of Russia gossiping. Kabaeva, a former Olympic rhythmic gymnast champion, is widely believed to be Putin's partner.
Rodnina and Tretyak lit the cauldron while Stravinksy's 'Firebird Suite' filled the stadium accompanied by more fireworks in a breathtaking climax to the ceremony.
There was more than a hint of political rebellion with one of the warm-up acts, the controversial pop act t.A.T.u who sang their 2003 number 'Not Gonna Get Us'. The duo Lena Katina and Julia Volkova held hands on the stage as they depicted a pair of teenage runaway lovers, which appears to challenge Putin's own views on "non-traditional sexuality."
International Olympic Committee president Thomas Bach called for "goodwill, tolerance, excellence and peace."
Addressing the many political leaders present he said: "Have the courage to address your disagreements in a peaceful, direct political dialogue and not on the backs of these athletes."
"The universal Olympic rules apply to each and every athlete, no matter where you come from or what your background is. You are living together in the Olympic village. You will celebrate victory with dignity and accept defeat with dignity. You are bringing the Olympic values to life.
"In this way, the Olympic Games, wherever they take place, set an example for a peaceful society. Olympic sport unites the people."