Cloud computing has transformed the way organizations store data, deploy applications, and manage digital infrastructure. Its scalability, flexibility, and cost efficiency have made it an essential technology for modern businesses. However, as cloud environments grow in size and complexity, they also become more vulnerable to various cybersecurity threats. Issues such as misconfigurations, insecure APIs, weak authentication mechanisms, and unauthorized access can expose cloud systems to serious security risks. Traditional security mechanisms such as firewalls and rule-based intrusion detection systems often struggle to detect new or evolving threats in dynamic cloud environments.To address these challenges, this work explores the use of machine learning techniques to improve cloud security by predicting and detecting vulnerabilities in distributed systems. The proposed approach analyses security-related data such as system logs, network traffic patterns, and vulnerability reports to identify abnormal behaviour and potential threats. Multiple machine learning algorithms, including Decision Tree, Support Vector Machine (SVM), Random Forest, K-Nearest Neighbors (KNN), and Isolation Forest, are evaluated to determine their effectiveness in detecting security vulnerabilities.The experimental results indicate that ensemble models, particularly Random Forest, provide higher accuracy and better detection capability compared to other algorithms. Machine learning-based security systems can analyse large volumes of data in real time, identify suspicious patterns, and respond to potential threats more quickly than traditional security approaches.By integrating machine learning into cloud security frameworks, organizations can build more proactive and intelligent defence systems capable of adapting to evolving cyber threats. The proposed approach enhances vulnerability detection, reduces response time to security incidents, and supports the development of more resilient and secure cloud infrastructures.