Born in Madison County, Alabama, Shelby was the son of Dr. David Shelby, and grandson of one-time Republic of Texas Supreme Court justice Anthony B.
[1] He attended Cumberland University and read law to enter the bar in 1870.
[2] He was a soldier in the Confederate States Army during the American Civil War.
[3] Owing to his youth he was not regularly enlisted in the Confederate Army, but served four months with the 4th Alabama Cavalry Regiment, in a Georgia campaign.
He was confirmed by the United States Senate on March 2, 1899, and received his commission the same day.