Basing on the coagulation model of Ossenkopf (1993A&A...280..617O), we systematically computed and tabulated the opacity of dust in dense protostellar cores between 1 micrometers and 1.3 mm. The possible physical conditions were varied especially considering the influence of different gas densities and molecular depletion ratios. In comparison to the dust opacity in the diffuse interstellar medium, we found nowhere changes by more than the factor 5 for ice-covered dust grains. Possible uncertainties and deviations in environments with different physical conditions are discussed. Although one may imagine very special situations in which the dust opacity is changed by more than a factor 10, for physically reasonable conditions in dense protostellar cores, all possible deviations from the tabulated values may not sum up to more than a factor of 2. Using these tables of dust opacities, the submm continuum radiation of cold dust in protostellar cores is a good tracer of their total mass.