Ankylosing spondylitis is a common chronic progressive inflammatory disease that mainly affects the mid-spine, lumbosacral joints and large joints near the trunk. The prevalence of hip involvement is 25% to 50%, with bilateral involvement accounting for 90% of cases. Hip joint lesions eventually lead to hip flexion and ankylosis, which affects joint function and quality of life, and total hip arthroplasty is currently the best treatment option for advanced ankylosing spondylitis hip lesions. However, hip replacement in patients with ankylosing spondylitis involves the balance of the trunk spine, pelvis, hip and knee, and the sagittal balance of the trunk as an indicator of judgment involving the spine, pelvis, hip and knee has begun to receive attention and research in spine surgery, but has not yet received sufficient attention in the field of joint surgery. In patients with ankylosing spondylitis undergoing hip replacement, the joint surgeon must also perform a preoperative analysis from a sagittal perspective because the patient has compensatory anterior spine tilt and the pelvis will tilt back, resulting in posterior extension of the hip joint, leading to hip impingement (including cephalic socket impingement or impingement with the bone), causing the patient to experience pain and accelerated wear of the lined prosthesis after surgery, as well as possible compensatory knee flexion. Therefore, torso-sagittal balance has an important role to play in guiding and analyzing the treatment plan for hip surgery in such patients.