The type of surgery you have often depends on where the hip is fractured and how bad it is. In some cases, internal fixation is used. This is when pins, screws, or a rod is placed into the fractured bone to hold it in place as it heals. This is often done if the broken pieces of the bone can be lined up correctly. In other cases, part or all of the hip is replaced. This is done when there's a lack of blood supply to the head of the femur, or if internal fixation isn't advised.