Locally Optimal Block Preconditioned Conjugate Gradient (LOBPCG) is widely used to compute eigenvalues of large sparse symmetric matrices. The algorithm can suffer from numerical instability if it is not implemented with care. This is especially problematic when the number of eigenpairs to be computed is relatively large. In this paper we propose an improved basis selection strategy based on earlier work by Hetmaniuk and Lehoucq as well as a robust convergence criterion which is backward stable to enhance the robustness. We also suggest several algorithmic optimizations that improve performance of practical LOBPCG implementations. Numerical examples confirm that our approach consistently and significantly outperforms previous competing approaches in both stability and speed.from which the approximate solution to the eigenvalue problem is extracted can become linearly dependent. This problem becomes progressively worse when the number of eigenpairs to be computed becomes relatively large (e.g., hundreds or thousands). For example, in electronic structure calculations, the number of desired eigenpairs is proportional to the number of atoms in the system, which can grow to several thousands [13]. Hence remedies for improving numerical stability are of practical interest.A strategy proposed in the work of Hetmaniuk and Lehoucq [8] addresses this issue. Their strategy is based on performing additional orthogonalization to ensure that the preconditioned gradient is numerically B-orthogonal to both the current and the previous approximations to the desired eigenvectors. However, this strategy can become expensive when the number of eigenpairs to be computed is relatively large. More importantly, reliability can still be severely compromised due to numerical instability within the orthogonalization steps.This paper presents an efficient and reliable implementation of LOBPCG. We develop a number of techniques to significantly enhance the Hetmaniuk-Lehoucq (HL) orthogonalization strategy in both efficiency and reliability. We also adopt an alternative convergence criterion to ensure achievable error control in computed eigenpairs. For simplicity, we assume that both A and B are real matrices. But our techniques naturally carry over to complex Hermitian matrices.The rest of this paper is organized as follows. In Section 2, we describe the basic LOBPCG algorithm. In Section 3, we discuss numerical difficulties one may encounter in LOBPCG and the HL strategy for overcoming these difficulties. In Section 4, we present our techniques for improving the HL strategy. In Section 5, we present additional techniques for improving all other aspects of LOBPCG. Finally, in Section 6, we report numerical experimental results to illustrate the effectiveness of our techniques.