Shelby formed the Lafayette County Mounted Rifles for Missouri State Guard service and was elected the company's captain, leading it into battle at Carthage, Wilson's Creek, and Pea Ridge. In 1862, he was promoted to colonel and authorized to recruit a Confederate cavalry regiment, returning to Lafayette County to do so. After successfully bringing the regiment safely back to Arkansas, he was given command of a brigade of newly recruited regiments.