Theriot, 30, was with the Dodgers for the final two months of the 2010 season after being acquired from the Chicago Cubs, for whom he played 5 1/2 years.
Theriot batted 270 with 20 stolen bases in 150 games last season. His best year was 2008, during which he batted .307 with a .387 on-base percentage in 149 games for the Cubs.
"Ryan is a perfect compliment to our roster," Cardinals General Manager John Mozeliak said. "He's a highly competitive player with a winning approach to the game. We expect him to be a key contributor to our middle infield."
Hawksworth went 4-8 with a 4.98 ERA in 90 1/3 innings last season for St. Louis, including eight starts. In his two years with the Cards, he went a combined 8-8 with a 4.07 ERA in 75 games.
Copyright 2010 United Press International, Inc. (UPI).