MIAMI (AP) _ A man claiming he had a bomb hijacked a Madrid-to-Havana flight Friday and demanded to be taken to Miami where he surrendered to police. All 232 people aboard were safely taken off the plane, and the bomb turned out to be fake.

Iberia Airlines Flight 6621 landed at Miami International Airport at 3 p.m., and once the DC-10 taxied to an open area in the middle of the airport, police stormed the plane.

``He indicated he had an explosive device and he told an air stewardess that he wanted to go to Miami,'' Metro-Dade police Detective Ed Munn said.

FBI spokesman Paul Philip in Miami gave hijacker's name as Saado Ibrahim, about 28, from Lebanon.

Philip said he would be charged with air piracy, a felony with a minimum sentence of 20 years in prison.

A Spanish government spokesman in Madrid, Francisco Garcia, said the Lebanese man left Beirut on Thursday and arrived in Madrid after a stop in Zurich, Switzerland. He had escaped from a refugee camp in southern Lebanon, Spanish Foreign Affairms Ministry spokesmna Inocencio Arias said in Madrid.

The ``bomb'' he displayed to the crew was just a tape recorder covered with aluminum foil, with a couple of wires pulled out, Garcia said.

According to Garcia, Ibrahim said, ``If I put these two wires together, this bomb will blow up.'' He also threatened the crew with a letter opener, Garcia said.

``There was never a bomb on board the plane,'' he said.

The hijacker was taken into custody by federal authorities, said Salvador Humbert, general manager of the Spanish airline in Miami. None of the 218 passengers or 14 crew members aboard was injured. The plane will not go to Havana until Saturday and the passengers will spend the night in Miami, Arias said.

``He simply did not want to go to Havana. He wanted to go to the U.S.,'' the FBI's Philip said.

Security officials at Barajas Airport in Madrid detected nothing unusual about the flight before it departed for Miami, the government's news service, Efe, reported.

Flight 6621 departed Madrid at 6:28 a.m. EDT for its daily nine-hour flight to Havana. The airline was notified of the hijacking at 1:45 p.m.

Negotiations in flight between the man and the FBI began an hour later, Philip said.

The hijacking comes a day after President Clinton announced tighter security measures at U.S. airports following the July 17 crash of TWA Flight 800 in New York.

The incident coincided with a national holiday Friday in Cuba commemorating the 1953 start of the communist revolution. President Fidel Castro was expected to use the occasion for a speech Friday night heralding signs of a long-awaited economic recovery.