Covid-19 (Coronavirus Disease-2019) is the most recent coronavirus-related disease that has been announced as a pandemic by the World Health Organization (WHO). Furthermore, it has brought the whole planet to a halt as a result of the worldwide introduction of lockdown and killed millions of people. While this virus has a low fatality rate, the problem is that it is highly infectious, and as a result, it has infected a large number of people, putting a strain on the healthcare system, hence, Covid-19 identification in patients has become critical. The goal of this research is to use X-rays images and computed tomography (CT) images to introduce a deep learning strategy based on the Convolutional Neural Network (CNN) to automatically detect and identify the Covid-19 disease. We have implemented two different classifications using CNN, i.e., binary and multiclass classification. A total of 3,877 images dataset of CT and X-ray images has been utilised to train the model in binary classification, out of which the 1,917 images are of Covid-19 infected individuals . An overall accuracy of 99.64%, recall (or sensitivity) of 99.58%, the precision of 99.56%, F1-score of 99.59%, and ROC of 100% has been observed for the binary classification. For multiple classifications, the model has been trained using a total of 6,077 images, out of which 1,917 images are of Covid-19 infected people, 1,960 images are of normal healthy people, and 2,200 images are of pneumonia infected people. An accuracy of 98.28%, recall (or sensitivity) of 98.25%, the precision of 98.22%, F1-score of 98.23%, and ROC of 99.87% has been achieved for the multiclass classification using the proposed method. On the currently available dataset, the our proposed model produced the desired results, and it can assist healthcare workers in quickly detecting Covid-19 positive patients.