Irreversible pulpitis and apical periodontitis are inflammatory diseases caused by opportunistic bacteria with possible co-infection with latent herpesviruses. The objectives of this study are to identify herpesviruses, including human cytomegalovirus (HCMV), Epstein-Barr virus (EBV), herpes simplex virus (HSV-1), and Varicella zoster virus (VZV) in patients with irreversible pulpitis (n = 29) or apical periodontitis, either primary (n = 30) or previously treated (n = 23). Using primary and nested polymerase chain reaction (PCR) and reverse transcription-PCR, EBV DNA and RNA were present in endodontic pathoses in significantly higher percentages (43.9% and 25.6%, respectively) compared with healthy pulp controls (0% and 0%, respectively). HCMV DNA and RNA were found in measurable numbers in both endodontic patients (15.9% and 29.3%, respectively) and in healthy pulp controls (42.1% and 10.5%, respectively). HSV-1 DNA was found in low percentages in endodontic patients (13.4%), and only one patient showed the presence of VZV. In conclusion, EBV may be associated with irreversible pulpitis and apical periodontitis.