Hydroxyapatite (HA) coatings on titanium (Ti) substrates have attracted much attention owing to the combination of good mechanical properties of Ti and superior biocompatibility of HA. Incorporating silver (Ag) into HA coatings is an effective method to impart the coatings with antibacterial properties. However, the uniform distribution of Ag is still a challenge and Ag particles in the coatings are easy to agglomerate, which in turn affects the applications of the coatings. In this study, we employed pulsed electrochemical deposition to co-deposit HA and Ag simultaneously, which realized the uniform distribution of Ag particles in the coatings. This method was based on the use of a well-designed electrolyte containing Ag ions, calcium ions and L-cysteine, in which cysteine acted as the coordination agent to stabilize Ag ions. The antibacterial and cell culture tests were used to evaluate the antibacterial properties and biocompatibility of HA/Ag composite coatings, respectively. The results indicated the as-prepared coatings had good antibacterial properties and biocompatibility. However, an appropriate silver content should be chosen to balance the biocompatibility and antibacterial properties. Heat treatments promoted the adhesive strength and enhanced the biocompatibility without sacrificing the antibacterial properties of the HA/Ag coatings. In summary, this study provided an alternative method to prepare bioactive surfaces with bactericidal ability for biomedical devices.