Public attention toward the Free Nutritious Meal Program (Program Makan Bergizi Gratis/MBG) has increased following mass food poisoning incidents in various regions. Data from the National Nutrition Agency (Badan Gizi Nasional/ BGN) up to September 2025 recorded 6,517 affected students, while the Indonesian Education Monitoring Network (Jaringan Pemantau Pendidikan Indonesia/JPPI) reported 11,566 victims as of October 12, 2025. This situation triggered widespread discussion on social media, with YouTube serving as the main platform for public opinion. The large number of unstructured comments rendered manual analysis ineffective, necessitating the use of automated analytical methods. This study aimed to analyze public sentiment toward the MBG program and compare the performances of the Support Vector Machine (SVM) and Random Forest algorithms. This study adopts a quantitative approach using 7,522 YouTube comments as the initial dataset, which are processed through data collection, text preprocessing, data labeling, and TF-IDF feature extraction stages. Subsequently, the SVM and Random Forest models were trained and tested to classify sentiments into positive, negative, and neutral categories. The model performance was evaluated using Accuracy, Precision, Recall, and F1-Score metrics. After the preprocessing stage, the number of data points used in the sentiment analysis decreased compared to the initial dataset. This reduction resulted from data filtering, in which irrelevant, duplicate, or sentiment-unclear data were removed from the dataset. The final cleaned dataset consisted of 7,030 YouTube comments regarding the Free Nutritious Meal Program (MBG). The results show that public opinion is dominated by neutral sentiment (77.17% or 5,425 data points), followed by negative sentiment (15.21% or 1,069 data points), which proportionally exceeds positive sentiment (7.62% or 536 data points). In the modeling stage, the Support Vector Machine (SVM) algorithm proved to be more robust and effective in handling imbalanced data than Random Forest. However, the Random Forest achieved a slightly higher accuracy (83.42% compared to 82.71%).