Peru and Chile signed the Treaty of Ancón, by which the Tarapacá province was ceded to the latter, bringing an end to Peru's involvement in the War of the Pacific.