Cyber attackers develop new malicious software to attack their targets every year. Recent sophisticated malware targets financial data and steals the credentials of users. Security analysts design novel methods to defend against malware attacks, but, unfortunately, with the proliferation of newly discovered malware, the methods are inefficient. The need for automated detection of unknown and new malware is still challenging in cybersecurity research. Machine learning approaches are applied for malware detection, however, they require larger feature extraction and feature engineering. The proposed work analyzes and classifies malware based on visualization technique and employs Lightweight Convolutional Neural Networks deep learning model. The model performed better achieving an accuracy of 97% and 95% for the two malware datasets including benign samples. They did not require more hardware resources and model is trained with a low computational cost. The model was evaluated on Malimg dataset and Kaggle’s Microsoft Malware Classification Challenge (BIG 2015) dataset. © Springer Nature Singapore Pte Ltd 2020.