Objectives: The aim of this study was to evaluate the accuracy of four electronic apex locators (EALs) (DentaPort ZX, Raypex 5, Endo Master and VDW Gold) in detecting the major foramen using the clearing technique. Materials and Methods: Forty-eight extracted single-rooted extracted teeth with mature apices were used for the study and divided into four groups of 12 teeth each. All teeth were embedded in an alginate model. Electronic measurements were taken using a size 15 K-file attached to the holder. Then, the teeth were cleared and photographed under a stereomicroscope with a digital camera. The distance between the tip of the file and the major foramen was measured by using an image analysis software program. Positive and negative values were recorded when the file tip was beyond or short of the major foramen and zero value when the file tip and the major foramen coincided. Statistical analysis was performed using the Kruskal-Wallis and Chi-square tests at a significance level of 0.05. Results: Mean distance from the file tip to the major foramen were 0.302 0.202, 0.065 0.293, 0.117 0.475, and 0.258 0.160 mm in the DentaPort ZX, Raype 5, Endo Master, and VDW Gold groups, respectively. There were no statistically significant differences among the devices (P > 0.05) . Conclusion: Under the experimental conditions, all EALs showed an acceptable determination of the major foramen.