A US military service member and two US contractors have been killed in an al-Shabab attack on a military base in Kenya used by US and Kenyan military personnel, the US military said.

Two other Department of Defense personnel were wounded in Sunday's attack on the Manda Bay Airfield in Lamu county.

"The wounded Americans are currently in stable condition and being evacuated," Africa Command (AFRICOM) said in a statement.

More:

There were no immediate reports of Kenyan casualties while Kenya's military said five attackers were killed.

The attack by al-Shabab began before dawn and lasted around four hours, witnesses and military sources told Reuters news agency.

A Kenyan police report seen by Reuters said the attackers destroyed two planes, two US helicopters and multiple US military vehicles during their assault.

In a statement earlier on Sunday, al-Shabab claimed it had destroyed seven aircraft and three military vehicles, without providing other details. It also published pictures of masked gunmen standing next to an aircraft in flames.

The attack sent a dark plume of smoke into the air [Screengrab]

Kenyan military spokesman Colonel Paul Njuguna said the base had been secured.

"This morning at around 5:30am an attempt was made to breach security at Manda Air Strip. The attempted breach was successfully repulsed," he said in a statement.

"Arising from the unsuccessful breach a fire broke out affecting some of the fuel tanks located at the airstrip. The fire has been put under control."

There was no indication the attackers had managed to enter the base. The airfield is separate to another on Manda Island used by commercial flights to Lamu.

Al Jazeera's Haru Mutasa, reporting from Kenyan capital, Nairobi, said it was an audacious attack by the armed group.

"The base is heavily fortified and al-Shabab still managed to break through," Mutasa said.

"The area is near Boni forest where al-Shabab is thought to operate from. In the past, Kenyan security forces have been going in and out of that forest to try to weed out al-Shabab fighters," she added.

Al-Shabab has maintained a campaign of deadly bomb and gun attacks despite being ejected from their bases in the Somali capital, Mogadishu, and other areas years ago.

The group also carries out frequent attacks in neighbouring Kenya, which sent thousands of its troops into Somalia to fight it.

This attack comes nearly a year after al-Shabab launched a deadly suicide attack on the upscale 14 Riverside complex in Nairobi, killing 21 people.