Abstract — Traditional small-to-medium scale layer hen farms in Indonesia frequently rely on manual management practices, resulting in environmental instability, inconsistent productivity, and excessive labor demands. This paper presents the design, implementation, and evaluation of an Internet of Things (IoT)-based smart farming prototype for layer chicken coops, incorporating real-time environmental monitoring and automation of critical husbandry processes. The system is built around an ESP32 microcontroller interfaced with a suite of sensors: DHT22 for temperature and humidity, MQ-135 for ammonia concentration, LDR for light intensity, and an IR sensor for automated egg counting. Actuation is achieved via servo motors for scheduled feeding, relay modules controlling ventilation fans and lighting, and a water pump for automated cleaning. A custom web-based monitoring and control interface, developed using PHP and MySQL, delivers real-time dashboards, historical data logging, and manual override capabilities, offering improved stability over third-party MQTT solutions. Laboratory unit testing and a seven-day field deployment at Serayu Farm, Purbalingga, demonstrated that the prototype maintained temperature variation below 2 °C, achieved an average 15 % reduction in ammonia levels, attained 94 % accuracy in egg counting, and reduced manual interventions by approximately 70 %. With a component cost under Rp 800 000 per unit, the system provides a practical, scalable solution for enhancing operational efficiency, animal welfare, and egg productivity in resource-constrained layer hen farming operations.
Copyrights © 2026