France's Luc Alphand took victory in the Dakar Rally for the first time, but his triumph was overshadowed by the three deaths that have marred the race.
Former skiing champion Alphand finished second last year
Sunday's final stage was not timed as a tribute to the two young spectators who were killed and Australian motorcyclist Andy Caldecott, who died on stage nine.
Former ski champion Alphand effectively sealed victory on stage 12 when leader Stephane Peterhansel crashed.
Spanish rider Marc Coma won the motorbike category for the first time.
Coma beat reigning champion Cyril Despres of France into second spot with Italy's Giovanni Sala finishing third.
Coma, the second Spaniard to win after Nani Roma in 2004, claimed victory without winning a single stage.
Driving a Mitsubishi, Alphand won the cars division with a lead of nearly 18 minutes over Volkswagen driver Giniel De Villiers of South Africa.
"This was definitely the most exciting Dakar Rally that I have been involved in," said Alphand, the 1997 overall World Cup skiing champion.
Born 6 August 1965
Suffers series of injuries in first part of skiing career, including abdomen tear and detached knee ligaments
Wins first World Cup downhill race in 1995
Ranked number one in men's downhill in 1995 and 1996
Wins World Cup in 1997 and retires at the end of the season
Competes in first Dakar Rally a year later in 1998
"I knew I had a chance. Our team was up against it in Morocco, but we were confident that our experience and our car would be stronger in Mauritania."
Alphand was ranked number one in men's downhill in 1995 and 1996 and retired at the end of the 1997 season in which he won the World Cup.
A year later, he entered his first Dakar Rally.
"It was a different world," he said after triumphing on Sunday.
"I had a good advantage from the vision and the ability to analyse speeds but you need time to learn.
"I was not really prepared for the desert. I was born for zero degrees and heights of 1500m. Being outside in the winter was my life.
"The desert is a different world. It was scary for me at the start.
"The first Dakar was a nightmare. We finished in a helicopter two days before the finish and left the car in the desert. I said to myself I did not want to be there again."
However, despite Alphand's remarkable achievement, the thoughts of many spectators in Senegal were with the families of the two young boys who were killed on consecutive days.
The first was hit by a competitor during the 13th stage and the second by a support vehicle on stage 14.
"Of course, we are thinking of them and their families," said Alphand.
Australian Caldecott, who won the third stage of this year's race, became the 23rd competitor to be killed in the 28-year history of the Dakar Rally when he crashed on Monday.