Abstract Background The use of implantable cardiac electronic devices (CEDs), including pacemakers, implantable cardioverter-defibrillators, and cardiac resynchronized therapy (CRT), is increasing worldwide for the treatment of cardiac arrhythmias. The aim of this work was to evaluate the effectiveness of PECS I, PECS II blocks as the primary anesthesia technique in patients undergoing subcutaneous pacemaker in comparison to local infiltration anesthesia. Methods This prospective cohort randomized study was carried out on 40 patients between the ages of 21 to 80 years old undergoing pacemaker implantation in Aswan heart center. Patients were randomly allocated into two equal groups: Group (1): received Pecs block and group (2): control group, received standard local infiltration anesthesia with lidocaine 0.2 (10-15ml).All patients were subjected tolaboratory examinations) Hemoglobin, platelet count international normalized ratio, prothrombin time, partial thromboplastin time), Echocardiography (ECG), VAS, PCIA and preoperative medications. Results Number of patients required postoperative analgesia was significantly lower in group 1 compared to the group 2 (P value <0.001). Time to first require analgesia was significantly delayed in PECS blocks group compared to the control group and postoperative analgesia was significantly lower in group 1 compared to the group 2 (P value <0.001). The hospital stay was significantly lower in PECS blocks group compared to control group (<0.001). Conclusions Ultrasound guided PECs provided adequate analgesia as shown by reducing the times of start procedure and technique, postoperative pain scores and total opioid usage, delayed the time to first require analgesia and better operator and patient satisfaction in pacemaker implantation as compared to infiltration anesthesia.