In [Erlangga and Nabben, SIAM J. Sci. Comput., 30 (2008), pp. 1572–1595], we developed a new type of multilevel method, called the multilevel Krylov (MK) method, to solve linear systems of equations. The basic idea of this type of method is to shift small eigenvalues that are responsible for slow convergence of Krylov methods to an a priori fixed constant. This shifting of the eigenvalues is similar to projection-type methods and is achieved via the solution of subspace or coarse level systems. Numerical results show that MK works very well for the two-dimensional (2D) Poisson and convection-diffusion equation, i.e., the convergence can be made almost independent of the grid size h and the physical parameter involved. In a follow-up paper we have used MK in the context of the preconditioned Helmholtz equation. For this problem, we show that the convergence can be made only mildly dependent on the wavenumber. Even though the coarse level system of MK is algebraically related to that of multigrid, the construction of interlevel transfer operators does not require a smoothness condition; MK requires only that the interlevel transfer matrices are full rank. We will highlight in detail the differences between multigrid methods on one side and MK methods on the other side. This means that many multigrid transfer operators are more than sufficient for MK and henceforth can potentially be used in the MK framework. Motivated by the evolution of geometric to algebraic multigrid methods (AMG), in this paper we bring the algebraic way of choosing the coarse level system and the transfer operators into the MK context. We evaluate two techniques common in AMG: the interpolation-based technique, in particular that of Ruge and Stüben, and the aggregation-based technique. The resulting MK method is thus called the algebraic multilevel Krylov method (AMK). Both techniques are tested for various matrices arising from discretization of some 2D diffusion and convection-diffusion problems, as well as for several matrices taken from the matrix-market collections. The numerical results show that AMK works as well as the geometric MK methods. For the convection-diffusion equations, AMK leads to better convergence rates than Ruge–Stüben's AMG with lexicographic Gauss–Seidel relaxation.