The dey was chosen by local civilian, military, and pirate leaders to govern for life and ruled with a high degree of autonomy from the Ottoman sultan. The main sources of his revenues were protection payments rendered by the Barbary pirates who preyed on Mediterranean shipping and the slave trade, most of the slaves being persons who had been captured by the pirates.
The dey was assisted in governing by a divan made up of the Chiefs of the Army and Navy, the Director of Shipping, the Treasurer-General and the Collector of Tributes.
The dey's realm was divided into three provinces (Constantine, Titteri, and Mascara), each of which was administered by a bey whom he appointed.
The rule of the deys came to an end on 5 July 1830 when Hussein Dey (1765-1838) surrendered to invading French forces.