Alkanes of medium chain length show an unusual wetting behavior on (salt) water, exhibiting a sequence of two changes in the wetting state. When deposited on the water surface at low temperatures, the liquid alkane forms discrete droplets that are interconnected only by a molecularly thin film. On increase of the temperature, there occurs a sudden jump of the film thickness and, at this first-order transition, a mesoscopically thick layer of liquid alkane is formed. Heating the system further leads to a divergence of the film thickness in a continuous manner. While the long-range forces between substrate and adsorbate are responsible for the critical transition, which occurs at the temperature at which the Hamaker constant changes sign, it is primarily the short-range components of the forces that bring about the first-order transition. We calculate the Hamaker constant of the system and show how, within a modified Cahn theory, accurate predictions of the first-order transition temperatures can be obtained for n-alkanes (pentane and hexane) on water and even on brine. Furthermore, we study the variation of the contact angle as a function of temperature. (C) 2004 Elsevier B.V. All rights reserved.