The war came to an end when the Nez Perce stopped to make camp and rest on the prairie adjacent to Snake Creek in the foothills of the north slope of the Bear's Paw Mountains in Montana Territory, only 40 miles from the Canada–United States border.