Water typically diffuses in and out of cells depending on the concentration of solutes (other gunk not water) in both the cell and the external environment. Osmosis (the diffusion of water), happens from where the solute concentration is lowest to where the solute concentration is highest (or more sensibly, water travels to dilute the solute; so imagine if a cell with a lot of gunk in it swims into pure water, water will start to move into the cell).