Spain tried to restore by force its influence on its former colonies, Chile and Peru. This strong Spanish squadron occupied the Chincha Islands, very important to the economy of Peru. Peru received support from neighboring Chile, Ecuador and Bolivia. After several battles, the heavily damaged Spanish squadron was forced to withdraw to the Philippines for repairs. In 1866, Peru strengthened its fleet and sent ships to the Philippines in order to inflict retaliation on Spain. The Spaniards decided to use a weakening of the allies to send a new fleet to South America. The opposing forces gathered strength for the decisive battle of the Chincha Islands.