Cole Hamels and the Philadelphia Phillies have reached a six-year agreement worth a little more than $140 million, pending physical, sources said Wednesday.