A new collection of photodissociation and photoionisation cross sections for 102 atoms and molecules of astrochemical interest has been assembled, along with a brief review of the basic processes involved. These have been used to calculate dissociation and ionisation rates, with uncertainties, in a standard ultraviolet interstellar radiation field (ISRF) and wavelength-dependent radiation fields. The new ISRF rates generally agree within 30% with our previous compilations, with a few notable exceptions. The reduction of rates in shielded regions was calculated as a function of dust, molecular and atomic hydrogen, atomic C, and self-shielding column densities. The relative importance of shielding types depends on the species in question and the dust optical properties. The new data are publicly available from the Leiden photodissociation and ionisation database. Sensitivity of rates to variation of temperature and isotope, and cross section uncertainties, are tested. Tests were conducted with an interstellar-cloud chemical model, and find general agreement (within a factor of two) with the previous iteration of the Leiden database for the ISRF, and order-of-magnitude variations assuming various kinds of stellar radiation. The newly parameterised dust-shielding factors makes a factor-of-two difference to many atomic and molecular abundances relative to parameters currently in the UDfA and KIDA astrochemical reaction databases. The newly-calculated cosmic-ray induced photodissociation and ionisation rates differ from current standard values up to a factor of 5. Under high temperature and cosmic-ray-flux conditions the new rates alter the equilibrium abundances of abundant dark cloud abundances by up to a factor of two. The partial cross sections for H2O and NH3 photodissociation forming OH, O, NH2 and NH are also evaluated and lead to radiation-field-dependent branching ratios.