We construct a random matrix model for the bijection Psi between classical and free infinitely divisible distributions: for every d >= 1, we associate in a quite natural way to each *-infinitely divisible distribution P a distribution P-d(mu) on the space of d x d Hermitian matrices such that P-d(mu) * P-d(v) = P-d(mu*v). The spectral distribution of a random matrix with distribution P-d(mu) converges in d probability to Psi(mu) when d tends to +infinity. It gives, among other things, a new proof of the almost sure convergence of the spectral distribution of a matrix of the GUE and a projection model for the Marchenko-Pastur distribution. In an analogous way, for every d >= 1, we associate to each *-infinitely divisible distribution mu, a distribution L-d(mu) on the space of complex (non-Hermitian) d x d random matrices. If mu, is symmetric, the symmetrization of the spectral distribution of vertical bar M-d vertical bar, when M-d is L-d(mu)-distributed, converges in probability to Psi (mu).