A cobalt metal-organic framework (Co MOF)-ionic liquid (IL) nanocomposite comprising the base matrix of the electrode was developed with electropolymerized molecularly imprinted polymer consisting of o-phenylenediamine (oPD) to detect carcinoembryonic antigen (CEA), a biomarker of breast cancer. First, Co MOF was synthesized using hydrothermal synthesis, which was used as an electrically conductive skeleton and functionalized with an IL. Then, CEA was employed as a template in the electropolymerization of oPD-imprinted films on the surface of screen-printed carbon electrode. Finally, the template protein was removed to form a molecularly imprinted film capable of qualitatively and quantitatively signaling CEA. Under optimized conditions, the sensor for CEA exhibits a wide detection range of 1.0×10-4-10 ng·mL-1 (0.32 V vs. Ag/AgCl) with a limit of detection and limit of quantification of 0.024 pg·mL-1 and 0.082 pg·mL-1, respectively. Besides, other parameters including the selectivity, reproducibility (RSD 2.2%), and recovery rate (92.16-103.35%) are all satisfactory. The proposed strategy provides a new route for the development of rapid breast cancer diagnostic tools.