Accurate and efficient localization of the optic disk (OD) in retinal images is an essential process for the diagnosis of retinal diseases, such as diabetic retinopathy, papilledema, and glaucoma, in automatic retinal analysis systems. This paper presents an effective and robust framework for automatic detection of the OD. The framework begins with the process of elimination of the pixels below the average brightness level of the retinal images. Next, a method based on the modified robust rank order was used for edge detection. Finally, the circular Hough transform (CHT) was performed on the obtained retinal images for OD localization. Three public datasets were used to evaluate the performance of the proposed method. The optic disks were successfully located with the success rates of 100%, 96.92%, and 98.88% for the DRIVE, DIARETDB0, and DIARETDB1 datasets, respectively.