WASHINGTON — A senior administration official says the helicopter that crashed Saturday carrying 31 U.S. special operations forces and seven Afghan soldiers was apparently shot down by insurgents in Afghanistan.

The official spoke on condition of anonymity because the crash is still being investigated.

Posted at 8:07 a.m.

KABUL, Afghanistan  — A helicopter crash in Afghanistan’s eastern Wardak province killed 31 U.S. special operation troops and seven Afghan soldiers, the country’s president said Saturday. It was the highest number of American casualties recorded in a single incident in the decade-long war.

President Hamid Karzai sent his condolences to President Barack Obama, according to a statement issued by his office.

“A NATO helicopter crashed last night in Wardak province,” Karzai said in the statement, adding that 31 American special operations troops were killed. “President Karzai expressed his deep condolences because of this incident and expressed his sympathy to Barack Obama.”

The Taliban claimed to have brought the helicopter down with a rocket attack, but they have been known to make exaggerated claims in the past.

NATO confirmed the overnight crash and said there “was enemy activity in the area.” But it said it was still investigating the cause. The alliance was conducting a recovery operation at the site, it said, without releasing details or a casualty figure.

“We are aware of an incident involving a helicopter in eastern Afghanistan,” said U.S. Air Force Capt. Justin Brockhoff, a NATO spokesman. “We are in the process of accessing the facts.” The helicopter was a twin-rotor Chinook, which are used for transport, said an official at NATO headquarters in Brussels, speaking on condition of anonymity because he was not authorized to talk to the press.

The helicopter crashed in the Sayd Abad district of Wardak province, said a provincial government spokesman, Shahidullah Shahid. The volatile region borders the province of Kabul where the Afghan capital is located and is known for its strong Taliban presence.

Taliban spokesman Zabiullah Mujahid said in a statement that NATO had attacked a house in Sayd Abad where insurgents were gathering Friday night, killing eight fighters. The Taliban then downed the helicopter. he said.

In June 2005, 16 American troops were killed when a U.S. helicopter crashed in eastern Kunar province after apparently being hit by a rocket-propelled grenade.

Aircraft crashes are relatively frequent in Afghanistan, where insecurity and difficult terrain make air travel essential for coalition forces transporting troops and equipment.

There have been at least 17 coalition and Afghan aircraft crashes in Afghanistan this year. Most of the crashes are attributed to pilot errors, weather conditions or mechanical failures. However, the coalition has confirmed that at least one CH-47F Chinook helicopter was hit by a rocket propelled grenade on July 25, injuring two crewmembers.

Meanwhile, NATO troops attacked a house and inadvertently killed eight members of a family, including women and children, in the southern Helmand province, an Afghan government official said Saturday.

NATO said Taliban fighters fired rocket propelled grenades and small arms at coalition troops during a patrol Friday in the Nad Ali district. The troops fired back, and as the fight escalated an aistrike was called in against the Taliban position, said Brockhoff, the NATO spokesman. He said NATO sent a delegation to meet with local leaders and investigate the incident.

Nad Ali district police chief Shadi Khan said civilians died in the bombardment but that it was unknown how many insurgents were killed.

Helmand, a Taliban stronghold, is the deadliest province in Afghanistan for international troops.

NATO has come under harsh criticism in the past for accidentally killing civilians during operations against suspected insurgents. However, civilian death tallies by the United Nations show the insurgency is responsible for most war casualties involving non-combatants.

Also in the south, NATO said two coalition service member were killed, one on Friday and another on Saturday. The international alliance did not release further details.

The deaths bring to 334 the number of coalition troops killed this year in Afghanistan, and 11 this month.