Many fears weaken because of habituation and extinction learning: when a feared situation is repeatedly met without the expected harm, the brain updates its prediction and the fear response gradually calms. Exposure to a feared thing, whether gradual or sudden, gives the brain new evidence that the threat is smaller than it seemed.
Not every fear fades on its own, though. Fears tied to a strong, traumatic experience can persist, and avoiding the feared thing prevents the learning that would weaken it, which is why exposure-based therapy works. Memories also change with time, so the emotional charge of an event often softens even as the facts stay the same.