By diagonalizing a matrix via a similarity transformation, we provide a new and direct proof of Sylvester's theorem in matrix theory. Several known theorems are reconstructed. In some places we offer new connections which are unnoticed in the literature before.