Proposed is a piecewise-uniform resampling technique for an ECG signal. Different waves of a heartbeat signal are resampled at different rates. The proposed method was tested on a large number of ECG signals with high and low sampling resolutions. It has been found that the piecewise-uniform resampling method helps to improve the morphology alignment in general. This improvement is significant (e.g. 206%) when the durations of different heartbeats vary largely. Improved morphology alignment of resampled heartbeats could be useful in many applications such as cardiovascular engineering and ECG-based biometrics.Introduction: Due to the heart rate variability (HRV) [1], the duration of different heartbeats of a person varies even within a short period of time. Thus, in a digital electrocardiogram (ECG) signal, each of the heartbeats may contain a different number of samples. Resampling of an ECG signal is often required in different applications such as cardiovascular engineering [2, 3] and ECG-based biometrics [4,5] to yield the same number of samples in each of the heartbeats. Generally the uniform resampling technique has been used [2,3]. This method ignores the deformation of morphology in resampled heartbeats. Hence, the non-uniform resampling technique has been evolved [4] to align the morphology. However, to the best of our knowledge, no work has analysed the morphology alignment in resampled heartbeats.In this Letter, we propose a piecewise-uniform resampling technique for a digital ECG signal so that the alignment of the heartbeat morphology is improved. Although durations of two heartbeats may differ due to the HRV, all ECG waves (e.g. P wave, QRS complex, and T wave) do not change uniformly [1,4]. This has motivated us to apply different resampling rates at different parts of a heartbeat.The proposed method has been tested on the ECG signals of a large number of persons obtained from two publicly available databases, namely PTBDB (PTB diagnostic ECG database: http://www. physionet.org/physiobank/ database/ptbdb) and NSRDB (MIT-BIH normal sinus rhythm: http://www.physionet.org/physiobank/database/ nsrdb) with different sampling resolutions. Three morphological features were extracted from a segmented and resampled heartbeat. For quantitative measurement of the morphology alignment between heartbeats of a person, we have introduced a metric called morphology alignment score (MAS). It has been found that for the piecewise-uniform resampling technique, MAS has been significantly improved (e.g. 206% and 32% with respect to the uniform and non-uniform techniques, respectively) when the durations of different heartbeats vary largely. This method is computationally very efficient and will be useful for different practical applications which utilise morphological features.