Mathematicians sometimes use heuristics to form expectations about what might be true or false. For examples, see Matthew Emerton's answer to Why should I believe the Mordell Conjecture?, this blog post by Terence Tao, and this expository article by Barry Mazur.
Such heuristics occupy a funny position in the epistemology of mathematics. We tend to think that using such heuristics somehow makes "more sense" than, say, reading tea leaves to decide which football team to bet on. We know they can be misleading, yet we allow ourselves to be influenced by them. Indeed, this MO question provides an example of heuristics leading to two contradictory conclusions.
Question: Has it ever happened that a conjecture supported by heuristics was proved, and then an explanation was found for the success of the heuristics? Concretely, this might mean that the heuristic argument was developed into a rigorous proof.
Example: When the umbral calculus was first discovered, it was mysterious that the seemingly nonsensical operation of "turning indices into exponents" could yield correct identities.
Example: The Cramér probabilistic model of the prime numbers predicts that the Riemann hypothesis is true. After the Riemann hypothesis is proved, as no doubt it eventually will, it would remain to be understood why the Cramér model was successful (at least in the case of RH).
Timothy Chow suggests in the comments that heuristics like the Cramér model are, in some sense, precise expressions of the imprecise hypothesis that "nothing weird happens".
Question: Have any attempts been made to formulate a conjecture that reflects the hypotheses underlying the Cramér model? Such a conjecture would be very powerful indeed, since it would imply the Riemann Hypothesis, Legendre's Conjecture, the Twin Prime Conjecture, and more.