And now Hamels is in Texas, traded on July 31 from the Phils to the Rangers. He is far from the beaches of Southern California. He is suddenly facing mostly American League hitters, not the guys from the National League he had grown up pitching against.
It is, Hamels said, a perfect fit.
Fact is, Hamels said the Rangers came out ranked No. 1 by he and his wife in an exercise they went through once it became apparent that the Phils were going to trade him as a part of a major rebuilding.
"We took all 30 teams, even the Phillies, and had 50 questions, each of which had a point system," Hamels said. "It had a lot of variables that were positive not only to the game, but to my family and to values as a person who doesn't play baseball."
The Rangers were ranked No. 1, ahead of his hometown Padres or the Dodgers or the Angels, all based in Southern California. Ahead of the Yankees or Cardinals or Giants, teams with championship legacies.
The Rangers like the way the pieces fit, too.
They were a bit of a surprise in the bidding for Hamels, given the fact they were struggling to get to .500 and were not considered a postseason contender.
Texas general manager Jon Daniels knew Hamels was under contract for three seasons after that with an option for a fourth, and he saw him as a critical part to a rebound for the Rangers, envisioning a 2016 rotation that would be anchored by the left-handed Hamels and right-hander Yu Darvish, who is recovering from Tommy John surgery.
Whatever happened in the final weeks of 2015 was a bonus.
Well, in Hamels' first 25 days with Texas, plenty has happened. A team that was 49-52 at the time the deal was made had won 15 of its past 22 games before Tuesday night's 6-5 loss to the Blue Jays, and fittingly moved into the No. 2 AL Wild Card spot Sunday when Hamels, in his fourth Rangers start, earned his first AL victory, a 4-2 decision at Detroit.
"We were not in the market for one of the top-end rentals like some of the others," Daniels admitted.
Sure David Price, who went from the Tigers to the Blue Jays, or Johnny Cueto, who went from the Reds to the Royals, or Scott Kazmir, who went from the A's to the Astros, are No. 1 quality starters who figure to impact the pennant race. But they all have free agency waiting at seasons' end.
Four weeks ago, Texas was thinking more about the future than the present. Then Hamels arrived. The Rangers started winning, and the thought process changed.
How much has it changed?
Well, on Tuesday the Rangers signed outfielder Drew Stubbs, who was released by the Rockies, to a Minor League contract. They see him as an elite basestealer who is a top-flight defensive outfielder in all three positions and has been inconsistent with the bat, but has legit power that can exploit left-handed pitchers.
And that came after the Aug. 7 addition of Mike Napoli from Boston for the famed "future considerations," and the Aug. 18 acquisition of left-handed-hitting outfielder Will Venable from the Padres.
Call it the Hamels factor.
The Rangers have played themselves into contention this month, so instead of being focused on next year, Daniels is looking for pitchers that can provide help in the next six weeks, and hopefully October, even if they are potential free agents at season's end.
"You never have enough depth," said Daniels, who has gone from rebuilding to fine-tuning. "Even in our best years, our bench and depth was not where we wanted it to be."
Most of all, though, the Rangers now see themselves with depth where it counts the most come October -- in the rotation.
Yovani Gallardo, acquired last winter from the Brewers to fill a void at the top of the rotation, is arguably the No. 3 now behind not only Hamels, but also Colby Lewis, who enters Wednesday's game against the Blue Jays having equaled a career-best with 14 victories, including six in his past seven starts.
Hamels is 1-1 with a 3.68 ERA in his first four starts with the Rangers, but he was initially slowed by groin soreness, which led his an extended rest between his second and third starts. He has had back-to-back quality starts since that then, and Texas has won both games.
More than that, Hamels' presence gave the clubhouse a feeling of hope that has turned into success on the field.
"It has been awesome," Hamels said of his brief exposure to the Rangers. "I don't know what part I had to do with it. I haven't been able to be the pitcher I feel I can be."
Hamels has, however, provided the presence that Texas needed. He is a No. 1 quality starting pitcher with a postseason history, and his arrival in the Lone Star State has coincided with the club's suddenly emergence at a viable postseason contender.
It is not a coincidence, even if it happened earlier than even the Rangers had expected.
Tracy Ringolsby is a national columnist for MLB.com.