We use the critical step model to study the major transitions in evolution on Earth. We find that a total of five steps represents the most plausible estimate, in agreement with previous studies, and use the fossil record to identify the potential candidates. We apply the model to Earth-analogs around stars of different masses by incorporating the constraints on habitability set by stellar physics including the habitable zone lifetime, availability of ultraviolet radiation for prebiotic chemistry, and atmospheric escape. The critical step model suggests that the habitability of Earth-analogs around M-dwarfs is significantly suppressed. The total number of stars with planets containing detectable biosignatures of microbial life is expected to be highest for K-dwarfs. In contrast, we find that the corresponding value for intelligent life (technosignatures) should be highest for solar-mass stars. Thus, our work may assist in the identification of suitable targets in the search for biosignatures and technosignatures.