The COVID-19 pandemic has been scattering speedily around the world since 2019. Due to this pandemic, human life is becoming increasingly involutes and complex. Many people have died because of this virus. The lack of antiviral drugs is one of the reasons for the spreading of COVID-19 virus. This disease is spreading continuously and easily due to some common mistakes by people, like breathing, coughing and sneezing by infected persons. The main symptom is the normal flu. Therefore, in the present condition, the best precaution for this disease is the face mask, which covers both areas of mouth & nose. According to the government and the World Health Organization, everyone should wear a face mask in busy places like hospitals and marketplaces. In today's environment, it's difficult to tell if someone is wearing a mask or not, and physical inspection is impractical since it adds to labour costs. In this research, we present a mask detector that uses a machine learning facial categorization system to determine whether a person is wearing a mask or not, so that it may be connected to a CCTV system to verify that only persons wearing masks are allowed in.