Heterotopic ossification is a well-known complication of surgical approaches to the hip that involve dissection of the gluteal muscles. Heterotopic ossification has been reported as an incidental finding on radiographs of as many as 84% of patients who have had total hip arthroplasty. This study evaluated the possibility of using rofecoxib, a COX II selective inhibitor, to prevent heterotopic bone formation after total hip replacement. Sixty consecutive patients operated by the same surgeon, using the same surgical approach (lateral approach) for total hip replacement and who were considered to be at risk for postoperative heterotopic ossification, were enrolled into this prospective study. The patients were randomly assigned to one of two treatment groups: group 1 received rofecoxib (25 mg) daily from the day after total hip replacement for three weeks; group 2 received no pharmacological treatment.