Cell formation is a procedure that involves identification of product families and their associated machine cells. This paper proposes a new cell formation algorithm, called heuristics rules-based logic (HERBAL), which belongs to the class of array-based matrix formulation algorithms. The algorithm incorporates the machine-component incidence (MCI) matrix to identify the component or part families and their associated machine groups. The algorithm, to an extent, overcomes some of the known drawbacks, such as in manipulating ill-structure machine-part matrices, attaining rational sizes of cells and employing weighted machine-part matrices. The proposed cell formation algorithm has been tested on a number of well-known data sets obtained from the literature as well as on a number of randomly generated data sets. In both cases, it has demonstrated successful groupings, in terms of the grouping efficiency, grouping efficacy and quality index measures.