A U.S. Air Force F-15E Strike Eagle from the 48th Fighter Wing lands at Incirlik Air Base, Turkey, Nov. 12, 2015. USAF/Airman 1st Class Cory W. Bush/Handout via Reuters

The United States borrowed an Israeli military tactic known as "roof knocking" to try to warn civilians before it dropped a bomb targeting Islamic State fighters in Iraq this month, but a woman was killed in the attack, a U.S. military official said on Tuesday.

The controversial tactic consists of firing a warning missile above or near an intended target, to give residents time to flee before the real strike.

The Israeli military used such "roof knocks" in the 2014 Gaza war, but a United Nations commission found in 2015 that the tactic was not effective, because it often caused confusion and did not give residents enough time to escape.

The United States used the tactic in an April 5 operation in the Iraqi city of Mosul. One woman who initially did leave the targeted building but then ran back inside was killed, a U.S. defense official said.

Air Force Major General Peter Gersten, deputy commander for operations and intelligence for the U.S.-led coalition, said the airstrike targeted a building that housed a member of Islamic State in charge of distributing money to fighters, as well as being a cash storage site.

U.S. intelligence and reconnaissance aircraft tracked the site and observed that a woman and children also frequented the house, which the United States believed to contain about $150 million.

Looking to ensure they and any other non-combatants were clear of the building, the military turned to a tactic used by the Israeli Defense Forces in some of its operations against Hamas militants, Gersten said.

The plan consisted of firing a Hellfire missile above the building "so it wouldn't destroy the building, simply knock on the roof to ensure that she and the children were out of the building," he said.

"We've certainly watched and observed their procedure," Gersten said of the Israelis, while noting that the military did not coordinate with the Israelis on the strike. "As we formulated the way to get the civilians out of the house, this (technique) was brought forward from one of our experts."

But the woman ran back into the building after the U.S. warplane had fired its weapon, Gersten said, adding that it was "very difficult for us to watch and it was within the final seconds of the actual impact."

The U.S.-led coalition could employ the roof knock technique again in the future, he said.

The air campaign against Islamic State militants in Iraq and Syria has been a key part of the U.S. plan to eventually destroy the hardline Sunni militant group.

But Islamic State's presence in major Iraqi and Syrian cities has made it difficult to destroy its most important headquarters, because of concerns about killing scores of innocents in the process.

The U.S. military acknowledges killing 41 civilians so far in the air campaign, which began in 2014.