There is no dress code as such in India. So just check the season you are traveling in.
If you are planning to come in between March & June, carry light clothes. Men can wear loose cotton shirts or T-shirts and baggy Pants/ jeans/ trousers. In the big cities and metros like Delhi, Mumbai, Banglore, Chennai etc. they can wear shorts also.
Women can wear jeans, trousers and long skirts. Try to avoid short tops, short skirts/ shorts, etc. Make sure that the clothes are not too tight or body revealing, especially when visiting religious places. It is advisable to carry a scarf to cover your head from hot sun. Some places of worship also require you to cover your head, so it can be used even then. These clothes can also be easily purchased from the Indian markets at a reasonable price. In case you want a different style and dress up in the Indian way, then men can wear “kurta-pyjama” and women can try “salwar-kameez”.
Winters (October to February) in India are quite cold, especially North India. So, pack some woolen clothes with you. And maybe some warm innerwear, which could be handy during sightseeing. During Monsoon (July to September), there is a high level of humidity in India, so cotton clothing is the best.