"It's a minor league contract with an invitation to spring training to earn the same spot that I had in 2010 when we won the World Series, " Mota said from Dominican Republic.
The Giants confirmed the deal to The Associated Press later Monday.
Mota, 37, had a 4.33 ERA in 56 games with the Giants last season.
The right-hander didn't allow a run in two appearances against the Texas Rangers in the World Series as San Francisco won the championship in five games.
Mota said that he had several similar offers, but chose to return to a place where he felt comfortable and for the chance to play with the defending champions.
Enrique Rojas is a reporter for ESPNDeportes.com.