  We study the distribution of the sandpile group of random d-regular graphs.
For the directed model, we prove that it follows the Cohen-Lenstra heuristics,
that is, the limiting probability that the $p$-Sylow subgroup of the sandpile
group is a given $p$-group $P$, is proportional to $|Aut(P)|^{-1}$. For
finitely many primes, these events get independent in the limit. Similar
results hold for undirected random regular graphs, where for odd primes the
limiting distributions are the ones given by Clancy, Leake and Payne.
  This answers an open question of Frieze and Vu whether the adjacency matrix
of a random regular graph is invertible with high probability. Note that for
directed graphs this was recently proved by Huang. It also gives an alternate
proof of a theorem of Backhausz and Szegedy.
