By Europe correspondent Rafael Epstein and wires
Emergency services say only 28 people survived after a plane crashed and burst into flames at Madrid airport. (Reuters: Juan Medina)
The Spanish Government says 145 people have died after a Spanish tourist jet carrying 173 people crashed on takeoff and burst into flames at Madrid airport.
The Spanair jet was lifting off to take 166 passengers and nine crew to the Canary Islands, but it barely made it off the ground before witnesses say an engine caught fire and the plane crashed in a field at the edge of the airport.
Dozens of ambulances and fire engines drove to the burning wreckage, which sparked a large grassfire that took more than an hour put out.
Plumes of smoke could be seen many kilometres away.
Around 25 passengers were treated for injuries, but it seems most of the passengers and crew were killed.
As large clouds of smoke billowed into the sky near the terminal at Madrid airport, there were reports that ambulance officers were pulling out burnt corpses and that the plane was completely destroyed.
Spanish newspapers say the plane, Spanair's Flight JK5022, an MD-82 jet, reported an engineering fault but was eventually allowed to take off.
The 15-year-old plane, carrying 166 passengers and nine crew, shot off the runway at 2:45 pm (local time), according to Spanair and witnesses described a huge explosion.
"Only the tail was recognisable, there was wreckage scattered all over the place and dead bodies across a wide area. A lot of them were children," Herbigio Corral, who headed the rescue effort, told reporters.
As well as helicopters dumping water on the fire, around 50 ambulances and more than 10 fire engines are reported to have arrived at the burning wreckage.
Less than a third of the passengers were treated at the crash site, while some were taken to the city's six hospitals.
Of the survivors, eight are in critical condition, an emergency services spokesman told national radio.
Spain's Prime Minister and Madrid's mayor went to the scene to talk to the families of those who had died.
Development Minister Magdalena Alvarez said the cause of the accident seemed to be "an error in takeoff".
But Spanish media quoted sources as saying the plane's left engine, made by Pratt & Whitney, had caught fire.
The flight was a code-sharing operation with Lufthansa serving the Canary Islands, a popular holiday destination for tourists from throughout Europe.
Lufthansa says seven passengers with Lufthansa tickets, four of them from Germany, had checked in for the flight, and a Canary Islands official says passengers included Swedes and Dutch.
Thick columns of smoke rose into the air and police blocked off both ends of the Terminal Four runway, where more than 20 ambulances and many fire engines were stationed.
"I saw how the plane broke in two and a huge explosion," Manuel Muela said , who was driving past the airport when the crash occurred, according to newspaper El Mundo.
Police escorted tearful relatives of passengers past reporters and dozens of workers identified as psychologists and social workers arrived at the terminal.
Spanish Prime Minister Jose Luis Rodriguez Zapatero interrupted his holidays and the Spanish Olympic Committee says the Spanish flag will fly at half mast in the Olympic village in Beijing.
Spain's national soccer team has worn black armbands at a friendly match with Denmark.
The MD-82 is a medium-range single-aisle plane, popular with regional airlines. It is a member of the MD-80 family of planes made by United States manufacturer Boeing Co.