In this paper, we propose a new technique to improve QRS complex detection. This technique consists of incorporating an autoencoder and bidirectional long short term memory (BiLSTM). The autoencoder used is a stacked autoencoder and functions as signal filtering. Meanwhile, BiLSTM is used as a detector. Exploration of the effect of hyperparameter in the autoencoder was also carried out to determine the effect on QRS complex detection. Furthermore, the dataset used in this study is the MIT-BIH arrhythmia database. Based on the experimental results, the hyperparameter in the autoencoder that gives a better effect on QRS complex detection is 16-8. Finally, the proposed method out-of-perform state of the art algorithm with accuracy 99.94%.