The fortress of Chelyaba, from which the city takes its name, was founded at the location of the Bashkir village of Chelyaby () by colonel Alexey (Kutlu-Muhammed) Tevkelev in 1736 to protect the surrounding trade routes from possible attacks by Bashkir outlaws. During Pugachev's Rebellion, the fortress withstood a siege by the rebel forces in 1774, but was eventually captured for several months in 1775. In 1782, Chelyabinsk became a seat of the uyezd of Ufa Viceroyalty, which was later reformed into Orenburg Governorate. In 1787, Chelyabinsk was granted town status by the government.