A Kubo-Greenwood-like equation for the Gilbert damping parameter α is presented that is based on the linear response formalism. Its implementation using the fully relativistic Korringa-Kohn-Rostoker band structure method in combination with coherent potential approximation alloy theory allows it to be applied to a wide range of situations. This is demonstrated with results obtained for the bcc alloy system Fe1−xCox as well as for a series of alloys of Permalloy with 5d transition metals. To account for the thermal displacements of atoms as a scattering mechanism, an alloy-analogy model is introduced. The corresponding calculations for Ni correctly describe the rapid change of α when small amounts of substitutional Cu are introduced.