Cancer classification is one of the crucial tasks in medical field. The gene expression of cells helps in identifying the cancer. The high dimensionality of gene expression data hinders the classification performance of any machine learning models. Therefore, we propose, in this paper a methodology to classify cancer using gene expression data. We employ a bio-inspired algorithm called binary bat algorithm for feature selection and extreme learning machine for classification purpose. We also propose a novel fitness function for optimizing the feature selection process by binary bat algorithm. Our proposed methodology has been compared with original fitness function that has been found in the literature. The experiments conducted show that the former outperforms the latter. Graphical Abstract Classification using Binary Bat Optimization and Extreme Learning Machine.