Introduction: This study proposes an algorithm for preprocessing VCG records to obtain a representative QRS loop. Methods: The proposed algorithm uses the following methods: Digital filtering to remove noise from the signal, wavelet-based detection of ECG fiducial points and isoelectric PQ intervals, spatial alignment of QRS loops, QRS time synchronization using root mean square error minimization and ectopic QRS elimination. The representative QRS loop is calculated as the average of all QRS loops in the VCG record. The algorithm is evaluated on 161 VCG records from a database of 58 healthy control subjects, 69 patients with myocardial infarction, and 34 patients with bundle branch block. The morphologic intra-individual beat-to-beat variability rate is calculated for each VCG record. Results and Discussion: The maximum relative deviation is 12.2% for healthy control subjects, 19.3% for patients with myocardial infarction, and 17.2% for patients with bundle branch block. The performance of the algorithm is assessed by measuring the morphologic variability before and after QRS time synchronization and ectopic QRS elimination. The variability is reduced by a factor of 0.36 for healthy control subjects, 0.38 for patients with myocardial infarction, and 0.41 for patients with bundle branch block. The proposed algorithm can be used to generate a representative QRS loop for each VCG record. This representative QRS loop can be used to visualize, compare, and further process VCG records for automatic VCG record classification.