Objective To construct polyhydroxyalkanoate (PHA) microspheres loaded with bone morphogenetic protein 2 (BMP-2) and human β-defensin 3 (HBD3), and evaluate the antibacterial activity of microspheres and the effect of promoting osteogenic differentiation, aiming to provide a new option of material for bone tissue engineering. Methods The soybean lecithin (SL)-BMP-2 and SL-HBD3 were prepared by SL-mediated introduction of growth factors into polyesters technology, and the functional microsphere (f-PMS) containing BMP-2 and HBD3 were prepared by microfluidic technology, while pure microsphere (p-PMS) was prepared by the same method as the control. The morphology of microspheres was observed by scanning electron microscopy and the water absorption was detected; the release curves of BMP-2 and HBD3 in f-PMS were detected by ELISA kit. The antibacterial effect of microspheres in Staphylococcus aureus and Escherichia coli was tested with the LIVE/DEADTM BacLightTM bacterial staining kit; the biocompatibility of microspheres was tested using Transwell and cell counting kit 8 (CCK-8). The effect of microspheres on osteogenic differentiation was determined by collagen type Ⅰ (COL-1) immunofluorescence staining and alkaline phosphatase (ALP) concentration. Results In this experiment, the f-PMS and p-PMS were successfully constructed. Morphological characteristics showed that p-PMS surface was rough and distributed with micropores of 1-3 μm, while f-PMS surface was smooth and existed white granular material. There was no significant difference in water absorption between the two groups (P>0.05). The release curves of BMP-2 and HBD3 in the f-PMS and p-PMS were basically the same, showing both early sudden release and late slow release. The antibacterial activity of f-PMS was significantly higher than that of p-PMS in the test that against Staphylococcus aureus and Escherichia coli (P<0.05), but there was no significant difference in biocompatibility between the two groups (P>0.05). The results of osteogenic differentiation of human BMSCs showed that the fluorescence intensity of osteogenic specific protein COL-1 of f-PMS was significantly higher than that in p-PMS, and the activity of ALP in f-PMS was also significantly higher than that in p-PMS (P<0.05). Conclusion The p-PHA have good antibacterial activity and biocompatibility, and can effectively promote the osteogenic differentiation of human BMSCs, which is expected to be applied to bone tissue engineering in the future.