Castro Valley was part of the original 28,000 acre (110 km²) land grant given to Castro, called Rancho San Lorenzo. This land grant included Hayward, San Lorenzo, and Castro Valley, including Crow Canyon, Cull Canyon, and Palomares Canyons. Castro had a gambling habit and had to sell off portions of his land to pay gambling debts. The last of his holding was sold in a sheriff's sale in 1864 to Faxon Atherton for $400,000.