The term was used to refer to the prison for hostages in Constantinople, which was near the bath-house, and thereafter all the slave quarters in the Ottoman Empire and the Barbary regencies. The hostages of the Barbary pirates slept in the prisons at night, leaving during the day to work as laborers, galley slaves, or domestic servants. The communication between master and slave and between slaves of different origins was made in a lingua franca known as Sabir or Mediterranean Lingua Franca, a Mediterranean pidgin language with Romance and Arabic vocabulary.
Bagnio was a term for a bath or bath-house. In England, it was originally used to name coffeehouses that offered Turkish baths, but by 1740 it signified a boarding house where rooms could be hired with no questions asked, or a brothel.
Bagne became the word for the prisons of the galley slaves in the French Navy; after galley service was abolished, the word continued to be used as a generic term for any hard labour prison. The last one in European France, the Bagne de Toulon, was closed in 1873.
This section does not cite any sources. (October 2011) (Learn how and when to remove this template message)
El trato de Argel (Life in Algiers, 1580), Los baños de Argel (The Bagnios of Algiers, 1615), El gallardo español (The Gallard Spaniard, 1615) and La gran sultana (The Great Sultana, 1615) were four comedies by Miguel de Cervantes about the life of the galley slaves, called "caitiffs". Cervantes himself had been imprisoned in Algiers (1575-1580). His novel Don Quixote also features a subplot with the story of a caitiff (chapters 39-41 of the first part).
A bagnio, in reference to a brothel or boarding house, is mentioned in The Private Memoirs and Confessions of a Justified Sinner (1824) by James Hogg as the location of a quarrel between two young Edinburgh nobleman that precedes one of them being murdered and the other arrested for the crime.
Frequent mention of a bagnio is made in A Maggot (1985) by John Fowles, set in 1736 and mainly written in the English of that time. In Fowles' novel, the term denotes a brothel, specifically the one run by 'Mistress Claiborne'.