Rise and fall of Italian occupation

At the beginning of the 18th century, the region began to break free of its Turkish rulers and enjoy greater autonomy. Its huge prosperity throughout the 18th and early 19th centuries was based almost entirely on revenue from piracy, which characterized the Barbary Coast at this time. By 1835, however, Ottoman rule was re-established in Libya.
The Italo-Turkish War, which began in 1911, resulted in Italy's annexation of Libya, and by 1934 the country was an Italian colony. Turkey renounced its interests in Libya in 1912, but fierce resistance to the Italians continued from the Sanusi sect, a strongly nationalistic group of Suni Muslims. This group held out against Italian settlement in the region for almost two decades, but were finally defeated in 1931, and its leaders sent into exile.
During the Second World War the exiled Sanusi leaders returned to Libya to fight on the side of the Allies. Both Italian and German forces were driven out of Libya by 1943, and control of Libya was shared between France and Britain.