867. The Shabbos Boundary
Shabbos 27:1
One who goes beyond the city's Shabbos boundary (techum) is liable to the punishment of lashes. Exodus 16:29 says, “No one may leave his place on the seventh day,” referring to the Shabbos boundary. The Torah did not specify the distance of the boundary but the Sages had a tradition that it was 12 mil (about 7.5 miles), which was the size of the Jews' camp in the wilderness. Moshe was therefore telling the Jews not to leave the camp on Shabbos. The Sages ruled that one may not travel more than 2,000 cubits beyond the city (about 2/3 of a mile). Traveling beyond 2,000 cubits is prohibited, 2,000 cubits being the size of the pastures that surround a city.
Shabbos 27:2
One may walk throughout the entirety of any city, walled or unwalled, even if it is as a major metropolis like Nineveh. Similarly, one may walk 2,000 cubits in any direction outside the city. Rather than a circle, the boundary is calculated as a square so that one benefits from the corners. If a person goes beyond 2,000 cubits and travels up to 12 mil, he is punished with stripes for acting rebelliously. If he goes even one cubit beyond 12 mil, he is punished with lashes.