CAIRO — Fighting between Islamist militias and rival groups in a western Libyan town has killed at least 23 people, a hospital official said Sunday.

The intense battle in Kikla also left 43 people wounded, mainly from shrapnel wounds, said the official, Emad Khalifa Abdul-Salam of the Gharyan hospital, southwest of the capital, Tripoli.

The fighting is part of a nationwide power struggle between Islamist-backed militias, which have seized control of most of Tripoli, including its international airport, and their opponents, who back an internationally recognized government based in the far eastern part of the country.

The anti-Islamist Zintan militia, named for its hometown in the west, attacked Kikla, an Islamist stronghold, on Saturday.