Computing in the cloud is becoming increasingly widespread, which has led to an increase in the demand for cloud-based search services that are not only effective but also confidential. This research proposes a novel method that combines Greedy Depth-First Search Encryption (GDFSE) and Multi-Keyword Ranked Search Algorithms (MKRSA) to improve the effectiveness and confidentiality of cloud-based searches. Our framework is primarily geared toward maximising the effectiveness of search operations while guaranteeing high data confidentiality. GDFSE provides a powerful encryption mechanism that effectively protects data from being accessed by unauthorised parties and from any potential breaches that may occur. In addition, MKRSA makes it possible to retrieve relevant data effectively based on the rankings of multiple keywords, which significantly improves the precision of search results. We carried out a series of experiments to evaluate the effectiveness of our integrated approach concerning the preservation of privacy, the efficiency of search, and the amount of computational overhead. Our approach is suitable for a wide range of applications that operate in cloud-based environments as a result of the results, which demonstrate a significant improvement in search efficiency without compromising privacy. The findings of this study not only present a novel approach to improving cloud search services, but they also lay the groundwork for further research on the safe and effective retrieval of data in cloud computing.