At least seven people have been injured after a US navy fighter jet crashed into apartment buildings in Virginia Beach, Virginia, on Friday afternoon.

The jet, an F/A-18 Hornet, crashed into buildings at 12.05pm local time after both pilots – who were among the seven injured – ejected from the plane.

Three residents of the Mayfair Mews complex for the elderly were unaccounted for, authorities said. Rescuers said they had completed 95% of their search.

Captain Mark Weisgerber, of US Fleet Forces Command, said the plane had suffered a "catastrophic mechanical malfunction" during a training flight. He said it had dumped a lot of fuel before crashing, although it was not clear if that was because of the malfunction or an intentional manoeuvre by the pilots.

The pilots were a student and an "experienced" instructor, Weisgerber said.

Thomas Thames, a doctor from Sentara Norfolk general hospital, told WAVY-TV that the two pilots were among those hospitalised.

Two people were treated for smoke inhalation, one fainted at the scene, and another was a police officer hurt at the scene, Thames said, adding that the pilots were not in a critical condition.

A witness, Kelly McQuaid, who lives near the apartment complex, said the jet had been on fire before it crashed. The pilot was said to have apologised for crashing to passersby who helped him after he ejected.

A spokesman for the Virginia Beach fire department told WVEC-TV that three buildings had been destroyed and two more damaged in the crash. Bruce Nedelka, chief of the Virginia Beach emergency medical services, said further damage had been averted because the pilot had dumped the jet's fuel before crashing.

"By doing so, he mitigated what could have been an absolute massive, massive fireball and fire," Nedelka said. "With all of that jet fuel dumped, it was much less than what it could have been."

Fuel was found on buildings and vehicles in the area – which has a concentration of military bases including the Naval Air Station Oceana, where the fighter jet was assigned.

Pictures posted to Twitter appeared to show the rear section of an aeroplane amid rubble, while what appeared to be an ejector seat was also photographed. Video footage showed a fire burning near the scene of the crash.

In a statement the Virginia Beach mayor, Will Sessoms, described the crash as horrific and asked the public to stay away from the scene to allow emergency services to continue work.

"Right now, we need to let the first responders do their jobs, so that we can find out more information about what happened and where we need to go from here," Sessoms said.

"I'm so proud of how quickly and effectively Virginia Beach's police, fire and EMS personnel responded to the scene of this horrific crash," he added. "Their dedication to their jobs, to saving lives, and to public safety is commendable, and we are lucky to have such heroes working for this fine city every day."

Sessoms said rescue workers would be attempting to enter damaged buildings to assess the aftermath of the crash.

Virginia's governor, Bob McDonnell, said he had been in contact with Sessoms to offer state resources.

"We are taking all possible steps at the state level to provide immediate resources and assistance to those impacted by the crash of an F-18 fighter jet in Virginia Beach," McDonnell said.

"In the past half hour, I have spoken to Virginia Beach mayor Will Sessoms several times and informed him that all commonwealth resources are available to him as the community responds to this breaking situation.

"We are monitoring events carefully as they unfold, and state police resources are now on the scene. Our fervent prayer is that no one was injured or killed in this accident."

The same model of fighter jet, an F/A-18D, crashed in San Diego, California, in December 2008 after suffering mechanical failure, the Associated Press reported. That crash killed four members of one family and destroyed two homes.