The failure knowledge of hydraulic component was expatiated based on the object-oriented method in this paper, and established a failure knowledge database. A fault reasoning strategy was defined, and given a detailed explanation of failure reasoning process, according to characteristics of directed tree and failure knowledge. A fault diagnosis expert system for hydraulic components was developed, which is structured based on VB language and SQL Server database technology. The system can diagnose failure occurred quickly and correctly, and provide a viable method of troubleshooting.