Ranchester was named by a local rancher who hailed from Great Britain. Back home, a lot of cities ended with the appellation "chester" (meaning "walled city"), so in honor of his several thousand-acre ranch, he came up with "Ranchester." The town grew up on the banks of the Tongue River, at that place where a loading dock was built for the railroad ties that were cut and hewn on the upper slopes of the Big Horn Mountains and were floated down to Dayton in a tie flume, then dumped in the Tongue River to float to the mill in Ranchester. Most of the railroad ties were for the further construction of the Chicago, Burlington & Quincy Railroad (which had arrived in Ranchester in 1896). The townsite of Ranchester was surveyed and platted in 1895 by the Lincoln Land Company (a fully-owned subsidiary of the CB&Q). The first lot was sold to JA Hartman, who first built a store, then a saloon.

At the south end of Ranchester is the site where troops under Brigadier General Patrick E. Connor attacked an encampment of Arapaho on August 22, 1865. As the Arapaho were breaking camp, Connor's men attacked and forced the tribe up Wolf Creek. Then the Arapaho counter-attacked and forced Connor and his men to retreat. During the fighting, Connor's men made no distinction between warriors, women and children, essentially shooting anyone who was not in an Army uniform. The Arapaho lost 64 people and several hundred of their ponies. Previous to this encounter, the Arapaho had never been hostile to the Americans. Afterwards, the Arapaho joined with the Sioux and the Cheyenne and engaged with the enemy Americans wherever they might find them.

These days, Ranchester is getting popular as a retirement destination. Ranchester is located on US Highway 14 on the eastern side of the Big Horn Mountains, between the I-90/I-25 and Yellowstone National Park.