To house prisoners-of-war
It was built for French and, then American, POWs. It was closed in 1815 when the prisoners were repatriated. After being largely rebuilt it was opened again in 1851 as a convict prison, closed again in 1917, when it was converted into a Home Office Work Centre for certain conscientious objectors granted release from prison, and then reopened in 1920.