A 66-year-old man is killed by a shark in the ocean near San Diego, the first person to die in a shark encounter off Southern California in nearly 50 years.

A 66-year-old man was attacked and killed by a shark in the ocean near San Diego on Friday, the first person to die in a shark encounter off Southern California in nearly 50 years.

The victim, identified as retired veterinarian David Martin, was swimming with a group of triathletes about 137 meters off Solana Beach north of San Diego when he was attacked by what experts said was probably a great white shark.

Solana Beach Deputy Fire Chief Dismas Abelman said rescue crews found Martin being dragged from the sea by other swimmers, bleeding profusely from injuries to his legs.

He was treated at the scene but was pronounced dead before an air ambulance could get him to a hospital.

"We are all shocked and dismayed at the events that happened here this morning," Solana Beach Mayor Joe Kellejian said. He urged residents to heed warnings by officials.

"We don't want people to panic. We do want them listen public safety officials," Kellejian said.

A 13 km stretch of beach was closed to swimmers for 72 hours while Coast Guard helicopters looked for the shark. Abelman said it would not necessarily be killed if it were found but, "We want to know where it is."

Authorities have not determined what species was involved, but experts said that given the size and severity of Martin's injuries it was almost certainly an adult great white.

It might have mistaken Martin for a seal, said Richard Rosenblatt, a marine biologist at the University of San Diego's Scripps Institution of Oceanography.

"Great whites normally feed on seals," he said. "They attack from below and make a tremendous, powerful rush and a very powerful bite, then pull away and wait for the seal or marine mammal to bleed to death before they come back."

George Burgess, curator of the International Shark Attack File at the University of Florida, told Reuters it was the first such death in Southern California since 1959.

Last year, the only fatal shark attack in the world was in New Caledonia, in the south-west Pacific, he said.

Attacks on the Atlantic coast are much commoner, especially in Florida, which has about 25-30 a year. They are rarely fatal because they usually involve a different species.