Cobb, who remained conscious the whole time despite being hit by a liner off the bat of Eric Hosmer, was taken to Bayfront Medical Center in St. Petersburg for further examination which revealed he had suffered mild concussion.
Luke Scott, Matt Joyce and Evan Longoria homered for the Rays, who had lost five of six.
Alex Torres (2-0) replaced Cobb and struck out four over 1 2-3 scoreless innings. Fernando Rodney pitched the ninth for his 14th save in 19 opportunities.
The Boston Red Sox edged the Baltimore Orioles 5-4 as Mike Carp and Jonny Gomes homered to back an effective pitching performance by John Lackey.
The win for Boston ended a five-game losing streak in Baltimore.
The Toronto Blue Jays were 6-1 winners over the Texas Rangers, Adam Lind and Colby Rasmus both hitting two-run homers.
The Blue Jays won their fourth game in a row to continue the Rangers' slide.
Houston beat the Chicago White Sox 4-3, Minnesota defeated Detroit 6-3, Los Angeles Angels won 6-2 over the New York Yankees and Seattle were 4-0 winners against Oakland.
In the inter-league game Washington edged Cleveland 7-6.
The Atlanta Braves won their National League match-up 6-5 with the San Francisco Giants as Freddie Freeman's bases-loaded, line-drive single off closer Sergio Romo capped a two-run rally in the ninth.
B.J. Upton hit two homers off Chad Gaudin.
The Los Angeles Dodgers needed 11 innings to beat the Pittsburgh Pirates 6-5, Juan Uribe singling home Andre Ethier in the top of the 11th inning.
Ethier doubled off Vin Mazzaro (3-1) leading off the 11th then raced home when Uribe's chopper went over the head of third baseman Pedro Alvarez.
The Chicago Cubs beat the New York Mets 5-2 as Scott Feldman allowed two hits in seven innings and Starlin Castro hit a two-run double to left in a three-run eighth inning.
Juan Francisco drove in three runs with a sacrifice fly and homer and Yovani Gallardo pitched six innings to lead the Milwaukee Brewers to a 6-0 blanking of the Cincinnati Reds.
The Colorado Rockies ended a three-game losing streak with a 10-5 win over the Philadelphia Phillies, Tyler Chatwood pitching five effective innings in his return from a triceps injury and Tyler Colvin homering during a six-run first inning.
The St Louis Cardinals outslugged the Miami Marlins 13-7, Carlos Beltran homering from each side of the plate and tripling to lead a 17-hit attack as Lance Lynn notched his ninth victory.
San Diego were 6-4 winners against Arizona.