A robust numerical algorithm for the calculation of multiple-scattering angular distributions of high-energy electrons and positrons is described. This algorithm implements the multiple-scattering theories of Goudsmit-Saunderson, which disregards energy losses, and of Lewis, which accounts for energy losses within the continuous slowing down approximation. We have used partial-wave elastic scattering differential cross sections, generated with a recently developed program elsepa, in the calculations. The contribution of inelastic collisions to multiple-scattering angular distributions is treated in detail using inelastic scattering angular differential cross sections obtained from the Sternheimer-Liljequist generalised oscillator strength model. The stopping powers adopted in the calculations are consistent with the values recommended in the ICRU 37 report. The coefficients in the Legendre expansion of the single-scattering distribution are calculated by using the N-point Gauss-Legendre integration formula, coded in such a way that it allows the generation of a large number of expansion coefficients simultaneously. A computer program has been written to calculate angular multiple-scattering distributions for given path lengths, which can be readily adopted for class I Monte Carlo simulations. 2005 Elsevier Ltd. All rights reserved.