so how does cranberry juice help? it can prevent bacteria from sticking to the walls of your kidneys, which helps prevent an infection from forming in the first place.