In this article, we have studied the photoluminescence (PL) behaviors of a-C:H and its alloys (a-C:H,N,F). The samples were deposited in a radio frequency plasma enhanced chemical vapor deposition system with various mixtures of CH4, N-2, and NF3 gases. For this work, the effects of doping and excitation energy on PL peak position and bandwidth were investigated in detail. It was found that with the decrease in Tauc gap, the PL peak shifts to lower energy and the bandwidth is narrowed. If the excitation energy is below a certain energy, the PL peak shifts to lower energy and the bandwidth is reduced through a cutoff of the high energy region. If the excitation energy is above a certain energy, the PL becomes saturated and the shape remains almost the same. Our results support the cluster model proposed by Robertson that a-C:H contains both sp(2) and sp(3) sites, with sp(2) clusters embedded in a sp(3) bonded matrix. Our PL data are explained by the distribution function of cluster gaps. (C) 1997 American Institute of Physics. [S0021-8979(97)05521-7].