Fire poses significant threats to buildings through-out their design lifespan, endangering human safety, causing property damage, and resulting in financial losses. Conventional fire detectors, which are predominantly sensor-based, exhibit limitations in effectively detecting fire and smoke. Consequently, computer vision-based fire detectors are emerging as a viable solution to address the shortcomings of sensor-based systems. Deep learning algorithms, including Convolutional Neural Networks (CNN) and Multilayer Perceptrons (MLP), can be leveraged to develop such computer vision-based fire detectors, with the application of transfer learning techniques. The training and testing of these models were conducted using a dataset from Kaggle titled “Forest Fire, Smoke, Non-Fire Image Dataset.” The evaluation of the models employed metrics such as accuracy, loss, precision, recall, and F1-score. The results indicate that the CNN model exhibits better performance than MLP in accurately classifying fire and smoke images, achieving an accuracy of 98.26% compared to MLP's accuracy of 97.09%. Tuned hyperparameter values included 40 epochs, a learning rate of 1e-05, and input dimensions of (244, 244, 3). The best-performing CNN model also attained a loss of 0.0735, precision of 0.9827, recall of 0.9826, and an Fl-score of 0.9825.