Santa Margarita is a located in San Luis Obispo California. The population was 1,259 at the 2010 census.

Located in the foothills of the Santa Lucia Mountains, it is one of the most rural areas in San Luis Obispo County. Santa Margarita Lake is a major water source for San Luis Obispo, is located several miles southeast of the town on the Salinas River.

The town is located on the Rancho Santa Margarita Mexican land grant and was granted to Joaquín Estrada, who later sold it to the Martin Murphy family. California culture is still very much alive at the Rancho, which remains in the private ownership of local developers Rob Rossi, Doug Filipponi, and Karl Wittstrom. It remains a working stock ranch and is also now home to the Ancient Peaks Winery.