The behaviour of water in nanopores is very different from that of bulk water. Close to hydrophobic surfaces, the water density has been found to be lower than in the bulk, and if confined in a sufficiently narrow hydrophobic nanopore, water can spontaneously evaporate. Molecular dynamics simulations have suggested that a nanopore can be switched between dry and wet states by applying an electric potential across the nanopore membrane. Nanopores with hydrophobic walls could therefore create a gate system for water, and also for ionic and neutral species. Here, we show that single hydrophobic nanopores can undergo reversible wetting and dewetting due to condensation and evaporation of water inside the pores. The reversible process is observed as fluctuations between conducting and non-conducting ionic states and can be regulated by a transmembrane electric potential.