In this paper, we derive a closed-form ergodic capacity expression for a generic cooperative diversity network (GCDN) in Rayleigh fading channels. We first derive a closed-form probability density function (pdf) of the instantaneous diversity-combined signal-to-noise ratio, and then a closed-form ergodic capacity expression for the GCDN by using the derived closed-form pdf. Through numerical analyses, we analyze the ergodic capacities according to the number of cooperative nodes (CNs), respective numbers of CN antennas, and respective channel qualities between a set of the CNs and a user terminal, and also characterize the resulting ergodic capacity behaviors.