ABSTRACT Machine Learning methods are most generally and effectively used to build up an intrusion detection system (IDS) to detect and distinguish at both network- and host-level in a mechanized and convenient way. Nonetheless, numerous difficulties emerge since security or cyber-attacks are consistently changing and are taking place in extremely enormous volumes that needs a versatile arrangement. Many datasets, for malicious attacks, are freely accessible for additional analysis by cyber safety organization. Attack datasets accessible freely needs to be upgraded on a methodical and standard basis because of the vital role of security attacks and that the attacking techniques are constantly changing. A proper study is necessary to learn the nature and performance of the various techniques used to develop a smart detection system for detecting and distinguishing numerous malicious attacks. Therefore, an effective comparison is made, providing a brief overview on various machine learning and deep learning algorithms used in developing a malleable and functional IDS that identifies and classifies unanticipated and unsought malicious attacks. This comparative analysis helps in finding the most suitable and finest algorithm that performs well in discovering upcoming security attacks. Keywords: Cyberattacks, Malware, Machine Learning, Deep Neural Network, Intruders, Dataset, Network Security