Unconfirmed reports that al-Zahawi was injured or killed in an attack late last year had circulated on jihadist websites for months although the group dismissed them at the time.
The statement, posted on the group's official Twitter account today, gave no details about how or when al-Zahawi was killed.
It gave condolences and vowed to take revenge and "shake the seat of power." The statement included a photo allegedly showing al-Zahawi after his death.
The group has been blamed for the September 2012 attack on the US Consulate in Benghazi that killed US Ambassador Chris Stevens and three other Americans.
Also Read
Stevens suffocated to death inside and another American was shot dead. Later in the evening, gunmen attacked and shelled a safe house, killing two more Americans.
The United States designated it a terrorist organization in January 2014, saying that the group emerged after the fall of longtime dictator Moammar Gadhafi.
It said that along with the attack on the US Consulate, the group has been involved in "terrorist attacks against civilian targets, frequent assassinations, and attempted assassinations of security officials and political actors in eastern Libya."
Ansar al-Shariah is part of the Shura Council of Benghazi Revolutionaries, an umbrella group for the city's hard-line militias.
Last spring Khalifa Hiftar, a former army general, led a unilateral offensive against extremist militias in Benghazi.