We present a numerical investigation of the gravitational collapse of horizon-size density fluctuations to primordial black holes (PBHs) during the radiation-dominated phase of the early Universe. The collapse dynamics of three different families of initial perturbation shapes, imposed at the time of horizon crossing, is computed. The perturbation threshold for black hole formation, needed for estimations of the cosmological PBH mass function, is found to be delta(c) approximate to 0.7 rather than the generally employed delta(c) approximate to 1/3 if delta is defined as Delta M/M-h, the relative excess mass within the initial horizon volume. In order to study the accretion onto the newly formed black holes, we use a numerical scheme that allows us to follow the evolution for long times after formation of the event horizon. In general, small black holes (compared to the horizon mass at: the onset of the collapse) give rise to a fluid bounce that effectively shuts off accretion onto the black hole, while large ones do not. In both cases, the growth of the black hale mass owing to accretion is insignificant. Furthermore, the scaling of black hole mass with the distance from the formation threshold, known to occur in near-critical gravitational collapse, is demonstrated to apply to primordial black hole formation. [S0556-2821(99)07310-5].