Trehalase catalyses the breakdown of trehalose into two glucose moieties and is ubiquitous in all organisms. Here, we provide insights into the enigmatic origin and evolution of trehalase in major species. Study of taxonomic distribution, orthology, phylogeny and functional domains indicated that trehalase possibly originates from bacteria and was transmitted to other taxa through horizontal gene transfer. Domain analysis showed that glycosyl hydrolase family 37 is present in most of the sequences and represents dominant activity during evolution, and also, illustrating that cytosolic trehalase is primitive than its transmembrane form. Furthermore, it was observed that trehalase went through domain rearrangement to facilitate its activity in adverse environmental conditions like acidic pH. Gene context analysis depicts that trehalase neighbourhood consists of sugar transport and lipid metabolism genes. This highlights their relatedness in metabolic activity and similarity in gene regulation, respectively. Evolutionary and selection pressure analysis demonstrated that trehalase genes were duplicated and evolved under purifying selection, following horizontal gene transfer. Moreover, site-specific rate of evolution emphasized conservation of functionally important residues. In comparison with acid trehalase, neutral trehalase has an extra N-terminal extension. This study serves as an instigation to understand evolution and functionality of trehalase across diverse species. Communicated by Ramaswamy H. Sarma.