Ibn Sina in his Canon said, 

“Cold water.

Water which is only moderately cold is more healthy than all others, because it stimulates the appetite and strengthens the stomach. Nevertheless it weakens the nerves and is harmful for cases of inflammatory disease in the interior organs. 

Very cold water should be taken after food and then only in small quantity (referencing Aegineta).

Tepid water incites nausea.

Warm water (that is, water which is a little warmer than tepid water), taken on an empty stomach, is cleansing both to stomach and intestines. But it has a weakening effect on the stomach if taken often. 

Hot water is beneficial for the following conditions: 

  1. Head: "cold" headache; inflammation of the eye; parotitis, quinsies; "dry" gums; postauricular inflammations.

  2. Mental conditions —epilepsy and “melancholia."

  3. Chest: asthma, solutions of continuity in the thorax; ulcers of the diaphragm.

  4. General: rheumatic pains. Diuresis. It relieves painful micturition.

  5. Female ailments : it evokes menstruation.

Hot water interferes with digestion and makes the food swim about in the stomach. It does not quench thirst. It may lead to dropsy, and hectic fever, and emaciation.

Very hot water is of great, value in colic; it also disperses flatulence.”