Casilla was hit while throwing batting practice to Casey McGehee.
"He was having fun with the hitters, getting on them because they weren't hitting him," Giants manager Bruce Bochy said.
Casilla suffered a bruised shin and could miss his next throwing session due to soreness.
NOTES: Reliever Sergio Romo is dealing with shoulder soreness and a throwing-hand injury. He was hit on his right hand while running in the outfield Wednesday, but Bochy didn't express much concern and said Romo will throw off the mound in a few days. ... Starter Matt Cain, coming off of elbow and ankle procedures last season, threw a bullpen session and is expected to take his turn in the rotation when exhibition play opens next week. ... World Series MVP Madison Bumgarner looked sharp pitching batting practice before Casilla's turn on the mound. "He's good to go. He's ready. This guy takes such great care of himself," Bochy said.