It is well-known that cardiovascular disease is one of the major causes of death worldwide nowadays. Electrocardiogram (ECG) sensor is one of the tools commonly used by cardiologists to diagnose and detect signs of heart disease with their patients. Since fast, prompt and accurate interpretation and decision is important in saving the life of patients from sudden heart attack or cardiac arrest, many innovations have been made to ECG sensors. However, the use of traditional ECG sensors is still prevalent in the clinical settings of many medical institutions. This article provides a comprehensive survey on ECG sensors from hardware, software and data format interoperability perspectives. The hardware perspective outlines a general hardware architecture of an ECG sensor along with the description of its hardware components. The software perspective describes various techniques (denoising, machine learning, deep learning, and privacy preservation) and other computer paradigms used in the software development and deployment for ECG sensors. Finally, the format interoperability perspective offers a detailed taxonomy of current ECG formats and the relationship among these formats. The intention is to help researchers towards the development of modern ECG sensors that are suitable and approved for adoption in real clinical settings.