Magnesium (Mg) alloys have attracted considerable research attention as potential biocompatible implant materials. However, the major barriers to the extended use of such medical devices are the possibility of high corrosion rate and implant-associated infections. To solve them, a novel polyacrylic acid (PAA)/gentamicin sulfate (GS)-hydroxyapatite (HAp) coating was synthesized by a one-step hydrothermal deposition method. Characteristics of functional coatings were investigated by SEM, FTIR and XRD. Corrosion properties of samples were evaluated by electrochemical and hydrogen evolution tests. Antibacterial activities of the coatings against Staphylococcus aureus (S. aureus) were measured by the plate-counting method. Results showed that the as-prepared HAp coating with dense and flawless morphologies could not only enhance the corrosion resistance of Mg alloys, but also improve the adhesion strength between the HAp coating and the substrate. In addition, the induction of the apatite coating during immersion confirmed the excellent mineralization ability of the HAp coating. Moreover, the obtained HAp coating possessed antibacterial properties and could prolong the release of GS. Thus, the PAA/GS-HAp coated Mg alloy could serve as a better candidate for biomedical applications with good anti-corrosion and antibacterial properties.