To evaluate in vivo the accuracy of two electronic apex locators (EALs) in determining the position of the apical foramen of teeth with large periapical lesions and persistent intracanal exudate. Thirty-three maxillary anterior teeth assigned for periapical surgery were selected. Following the preparation of standard endodontic access cavities, electronic working lengths were determined using the ProPex and Apex Pointer apex locators. During endodontic surgery, the actual root canal length of each tooth was measured by positioning a K-file at the most coronal border of the major foramen. Root canal treatments combined with apical surgery were then completed. Data were analysed with paired t-tests. ProPex and Apex Pointer were accurate (within ± 0.5mm) 97% and 94% of the time. No significant differences were detected between the apex locators (P=0.325). Despite the presence of exudate in the root canals, the position of the major foramen in teeth with large periapical lesions can be determined with high level of precision either by ProPex or Apex Pointer. Both EALs can be used safely in working length determination of teeth with large periapical lesions, which have persistent intracanal exudate.