Total hip arthroplasty (THA) is the most common and radical treatment for end-stage hip disease. Prosthesis loosening and periprosthetic infection are the most serious complications after THA, which may lead to prosthetic dysfunction. The early prevention of infection and the promotion of fast osseointegration between the prosthesis and host bone are essential to the success of THA. However, Ti6Al4V does not have biological function, such as promoting osseointegration and antibacterial properties, which limits its widespread use. Therefore, it is necessary to design a functional hip prosthesis to simultaneously reduce the incidence of loosening and periprosthetic infection. In this study, we developed a novel functionalized coating via micro-arc oxidation modification combined with vancomycin to treat a prosthetic surface for the early postoperative period to resist bacterial infection and promote osseointegration. The functionalized coating simultaneously prevents periprosthetic infections and promotes osseointegration at the prosthesis–host bone interface. We successfully constructed a prosthetic coating with the dual function of promoting osseointegration and preventing infection, which provides a practical and effective method for the treatment of periprosthetic infection and prosthetic loosening after THA.