The descent of Mars rover Curiosity was almost too painful to watch for many of the technical wizards packed into the Nasa Jet Propulsion Laboratory.
In a show of technological genius, the robotic explorer Curiosity blazed through the pink skies of Mars, steering itself to a gentle landing inside a giant crater for the most ambitious dig yet into the red planet's past.
A chorus of cheers and applause echoed through the Nasa Jet Propulsion Laboratory after the most hi-tech interplanetary rover ever built signalled it had survived a harrowing plunge through the thin Mars atmosphere.
"Touchdown confirmed," said engineer Allen Chen. "We're safe on Mars."
Minutes later, Curiosity beamed back the first black-and-white pictures from inside the crater showing its wheel and its shadow, cast by the afternoon sun - giving earthlings their first glimpse of a touchdown on another world.
It was Nasa's seventh landing on Earth's neighbour; many other attempts by the US and other countries to zip past, circle or set down on Mars have gone awry.
The arrival was an engineering tour de force, debuting never-before-tried acrobatics packed into "seven minutes of terror" as Curiosity sliced through the Martian atmosphere at 13,000mph (21,000kph).
In a Hollywood-style finish, cables delicately lowered the rover to the ground at a snail-paced 2mph (3kph). A video camera was set to capture the most dramatic moments.
The extraterrestrial feat injected a much-needed boost to Nasa, which is debating whether it can afford another Mars landing this decade. At a budget-busting 2.5 billion US dollars (£1.6 billion), Curiosity is the priciest gamble yet, which scientists hope will pay off with a bonanza of discoveries.
"We're on Mars again," said Nasa chief Charles Bolden. "It's just absolutely incredible. It doesn't get any better than this."
President Barack Obama tweeted his appreciation: "I congratulate and thank all the men and women of Nasa who made this remarkable accomplishment a reality."
Over the next two years, Curiosity will drive over to a mountain rising from the crater floor, poke into rocks and scoop up rust-tinted soil to see if the region ever had the right environment for microscopic organisms to thrive. It is the latest chapter in the long-running quest to find out whether primitive life arose early in the planet's history.
The voyage to Mars took more than eight months and spanned 352 million miles (566 million km). The trickiest part of the journey was the landing - because Curiosity weighs nearly a ton, engineers drummed up a new and more controlled way to set the rover down. The last Mars rovers, twins Spirit and Opportunity, were cocooned in air bags and bounced to a stop in 2004.
The plans for Curiosity called for a series of braking tricks, similar to those used by the space shuttle, and a supersonic parachute to slow it down. Next: Ditch the heat shield used for the fiery descent.
And in a new twist, engineers came up with a way to lower the rover by cable from a hovering rocket-powered backpack. At touchdown, the cords cut and the rocket stage crashed a distance away.
The nuclear-powered Curiosity, the size of a small car, is packed with scientific tools, cameras and a weather station. It sports a robotic arm with a power drill, a laser that can zap distant rocks, a chemistry lab to sniff for the chemical building blocks of life and a detector to measure dangerous radiation on the surface.
It also tracked radiation levels during the journey to help Nasa better understand the risks astronauts could face on a future manned trip.
Over the next few days, Curiosity is expected to send back the first colour pictures. After several weeks of health checks, the six-wheel rover could take its first short drive and flex its robotic arm.
The landing site near Mars' equator was picked because there are signs of past water everywhere, meeting one of the requirements for life as we know it. Inside Gale Crater is a 3-mile (5km) high mountain, and images from space show the base appears rich in minerals that formed in the presence of water.
Previous trips to Mars have uncovered ice near the Martian north pole and evidence that water once flowed when the planet was wetter and hotter, unlike today's harsh, frigid desert environment.
Curiosity's goal is to scour for basic ingredients essential for life including carbon, nitrogen, phosphorous, sulphur and oxygen. It is not equipped to search for living or fossil micro-organisms. To get a definitive answer, a future mission needs to fly Martian rocks and soil back to Earth to be examined by powerful laboratories.
The mission comes as Nasa retools its Mars exploration strategy. Faced with tough economic times, the space agency pulled out of partnership with the European Space Agency to land a rock-collecting rover in 2018. The Europeans have since teamed with the Russians as Nasa decides on a new roadmap.
Despite Mars' reputation as a spacecraft graveyard, humans continue their love affair with the planet, lobbing spacecraft in search of clues about its early history. Out of more than three dozen attempts - flybys, orbiters and landings - by the US, Soviet Union, Europe and Japan since the 1960s, more than half have ended disastrously.
One Nasa rover that defied expectations is Opportunity, which is still busy wheeling around the rim of a crater in the Martian southern hemisphere eight years later.
Video: Nasa celebrates landing
Crunch time for rover
By John von Radowitz
Two thirds of Mars missions to date have failed, including Britain's ill-fated Beagle 2 lander which was lost on Christmas Day 2003.
But none has been as complex and daring as the Mars Science Laboratory (MSL) mission, which aims to deliver the largest rover to land on the Red Planet.
Curiosity, costing £1.59 billion, is twice as long and five times as heavy as the twin rovers Spirit and Opportunity which landed there in 2004.
Because of its size and weight, getting the vehicle on to the Martian surface presented a major challenge to scientists at the American space agency Nasa.
The dramatic solution involves dropping the robot on nylon tethers from a hovering "sky crane".
John Bridges, from the University of Leicester, one of two British scientists leading teams on the mission, said: "I'm cautiously optimistic. Space exploration is not for the faint-hearted.
"The previous rover landing used inflatable bouncing bags. Curiosity's just too heavy for that, so they developed the sky crane technique."
Curiosity's target is Gale Crater, near the Martian equator, where billions of years ago there may have been a large lake.
The rover landed close to a Mount Sharp, a 5.5-kilometre peak in the middle of the crater with clay deposits round its base.
Curiosity bristles with sophisticated instruments designed to discover if Gale Crater could ever have supported simple life.
For one Martian year - 98 Earth weeks - the rover will explore its surroundings using a robot arm to scoop up soil and drill into rock.
It also carries its own laser gun for "zapping" rocks up to 30 feet away. The laser will vaporise tiny amounts of material in a flash of light that can be analysed to reveal chemical data.
As well as carrying a stereo camera for panoramic shots, Curiosity has a magnifying imager that can reveal details smaller than the width of a human hair.
Samples will be analysed using a state-of-the-art onboard laboratory.
The landing site bears geological signs of past water, including what appears to be a lake bed on the floor of the crater. Channels that may have been carved by flowing water have also been identified.
Dr Bridges said: "There's this idea that Mars was warm and wet long ago, but we don't know how long there were standing bodies of water on Mars, whether they were short-lived or lasted hundreds of millions of years. That's important to the question of whether life ever existed there."
An Atlas V rocket carrying Curiosity blasted off from Cape Canaveral, Florida, last November. The journey to Mars crossed 352 million miles of space.
Today's landing began with the capsule containing the rover first being slowed by friction as it enters the Martian atmosphere at 13,200mph, and then a supersonic parachute.
Closer to the ground, the "sky crane" descent stage was released, braking its fall with retro rockets.
Hovering above the surface, it dropped Curiosity on to the planet at the end of three 25ft nylon tethers.
Once the rover touched down, the descent stage will broke off and crashed a safe distance away.