The best time to visit Hampi is from October to February. This world heritage site is cool though not cold nor sweaty. Dry weather prevails all through the year in Hampi. Summers are scorching while rains are heavy.
The best time would be during winters that is from October to February. Hampi gets very hot during summers so I would suggest to plan it in winters only.