El Cajon is a city in San Diego County, California, United States, 17 mi east of Downtown San Diego. The city takes its name from Rancho El Cajón, which was in turn named for the box-like shape of the valley which surrounds the city, which is also the origin of the city's common nickname of "The Box."