Social media is referred to as active global media because of its seamless binding thanks to COVID-19. Connecting software such as Facebook, Twitter, WhatsApp, WeChat, and others come with a variety of capabilities. They are well-known for their low-cost, quick, and effective communication. Because of the seclusion and travel constraints caused by COVID-19, concerns, such as low physical involvement in many possible activities, have arisen. Depending on their information, knowledge, nature, experience, and way of behavior, various types of human beings have diverse responses to any scenario. As the number of net subscribers grows, inappropriate material has become a major concern. The world's most prestigious and trustworthy organizations are keenly interested in conducting practical research in this field. The research contributes to using Artificial Intelligence (AI) as a service (AIaaS) for preventing the spread of immoral content. As software as a service (SaaS) and infrastructure as a service (IaaS), AIaaS for immoral content detection and eradication can use effective cloud computing models to leverage this service. It is highly adaptable and dynamic. AIaaS-based immoral content detection is mostly effective for optimizing the outcomes based on big data training data samples. Immoral content is identified for semantic and sentiment evaluation, and content is divided into immoral, cyberbullying, and dislike components. The suggested paper's main issue is the polarity of immoral content that can be processed using an AI-based optimization approach to control content proliferation. To finish the class and statistical analysis, support vector machine (SVM), selection tree, and Naive Bayes classifiers are employed.