Tripoli was captured by a Spanish force led by Count Pedro Navarro in 1510, and most of the city's population was killed, enslaved or displaced in the process.
[2] An attack on the city was planned by Barbary pirates in 1512, and it was further threatened after Oruç Reis and Hayreddin Barbarossa captured Algiers from Spain in 1515.
[1] The Spanish made some repair works to Tripoli's castle by taking stonework from the city's fortifications, but the defences were otherwise neglected.
A delegation sent by the Hospitallers produced a report which stated that these locations were unfavourable, and they were reluctant to accept both Tripoli and the Maltese Islands because of the distance between them and the considerable expenses that would be necessary to maintain them.
[1] The Hospitallers eventually accepted Tripoli, Malta and Gozo as a fief on 23 March 1530, and they took control of the city on 25 July.