Cervical cancer is caused by persistent infection with high-risk strains of human papillomavirus (HPV). HPV is transmitted sexually and infects the cells of the cervix, which can lead to cervical cancer over many years if the infection is not cleared by the immune system. Screening for cervical cancer using the Pap test aims to detect cellular changes in the cervix before cancer develops. Diagnosis involves tests to detect HPV infection and examine cervical tissue for cancerous or precancerous cells. Prevention strategies include the HPV vaccine to protect against infection from high-risk HPV strains and regular Pap screening to detect cellular changes early.