H - matrices play an important role in the theory and applications. Different algorithms to determine H - matrices can be found in the literature. In [1] an algorithm is given, and this algorithm can determine if an irreducible matrix is an H - matrix or not. An improvement of this algorithm is given in [2] to include reducible matrices having a nonsingular comparison matrix. Nevertheless, there exist nonsingular H - matrices such that its comparison matrix is singular, and there are some singular H - matrices having some null diagonal entries, see [3], where the set of general H - matrices is partitioned in three classes: Invertible class, Mixed class and Singular class. In this paper, a new algorithm determining if a general matrix is an H - matrix or not is given. That is, this algorithm can be applied to reducible or irreducible matrices having singular or invertible comparison matrices. In addition, the algorithm finds the H - matrix class to which the original matrix belongs. To do that, the construction of the irreducible diagonal blocks of the matrix is given. The results are illustrated by some numerical examples.