When a photon that has an energy of at least twice the rest energy of an electron passes by an atomic nucleus, it turns into an electron and a positron. But why? Nothing I know about quantum/particle physics tells me why this should happen. From my very limited and unprofessional experience in particle physics, I can only venture a guess it's because the electric field around a nucleus is so strong that it becomes more energetically favorable to split the photon into an electron-positron pair and have them fall down their potentials than to keep the photon.
Technically, this can't be quite right, since the electric field is just an approximation of QED, but I don't know the QED equivalent of what would be happening.
Edit: The answer to this question here says pair production needs to happen around nuclei to conserve momentum. It's helpful to know, but it still doesn't explain why the photon doesn't stay a photon.