Indonesia’s coffee industry faces persistent threats from plant diseases and pests, which significantly impact crop yield and farmer livelihoods. Many smallholder farmers lack access to timely expert guidance, leading to delays in diagnosis and ineffective treatments. This study proposes a web-based expert system designed to assist farmers in diagnosing coffee plant diseases and pests based on observed symptoms. The system integrates a Bayesian Network (BN) to model the probabilistic relationships between symptoms and diseases. It employs a Breadth-First Search (BFS) algorithm to optimize the exploration of symptom-disease associations. Developed using Node.js, Next.js, and MySQL, the system enables users to input their symptoms and receive probabilistic diagnoses along with treatment suggestions. Validation results show over 85% accuracy compared to expert assessments, highlighting the system's reliability and scalability. This research demonstrates that combining probabilistic reasoning and structured graph traversal provides an effective diagnostic tool, especially for underserved rural communities. Furthermore, the system serves as a foundation for future development of intelligent agricultural support tools, with potential integration of real-time environmental data, mobile platforms, and adaptive learning models to enhance decision-making in precision farming.