Background Conventional room cooling systems generally operate at fixed fan speeds without considering variations in room temperature and occupant density, leading to reduced thermal comfort and inefficient energy consumption Purpose This study aims to design and implement an automatic room cooling system that adjusts fan speed based on room temperature and visitor density using Mamdani fuzzy logic control. Methodology The system integrates a DHT22 sensor to measure room temperature and an ultrasonic sensor to estimate visitor density. Mamdani fuzzy logic was employed to process linguistic variables for temperature ("cold," "normal," and "hot") and visitor density ("sparse," "crowded," and "very crowded") to determine the appropriate fan speed. Findings Experimental results demonstrate that the system successfully adjusts fan speed according to environmental conditions. At 17°C with 6 visitors (sparse), the fan operates at low speed (PWM = 39.6), while at 34°C with 37 visitors (very crowded), it reaches high speed (PWM = 211). Under moderate conditions (22°C with 25 visitors), the fan operates at medium speed (PWM = 125), indicating effective adaptive control. Implications The proposed system improves occupant comfort while promoting energy efficiency through adaptive fan speed control. It can be applied in meeting rooms, seminar halls, conference rooms, and other indoor environments with dynamic occupancy levels. Originality This study presents an adaptive room cooling system that integrates room temperature and visitor density using Mamdani fuzzy logic, providing a practical and energy-efficient solution for intelligent indoor environmental control.