This paper considers the relationship between human resource management (HRM) and knowledge management (KM). Specifically, it examines how the human resource (HR) practices that are expected to impact on employees' abilities, motivation, and opportunity to engage in KM, do so by enabling knowledge sharing, knowledge maintaining, and knowledge creation within organizations. HRM expected to impact employees' abilities include training and development practices. HRM expected to impact on employees' motivation include rewards and appraisal practices. HRM expected to impact on employees' opportunities including providing the support of trusting collaborative relationships. Therefore, HR practices impacting employees' abilities, motivation, and opportunities are expected to be positively related to knowledge sharing and maintaining within organizations. HR practices impacting employees' abilities, motivation, and opportunity are expected to be positively related to knowledge creation through their effect on knowledge sharing within organizations. Our research methodology uses a questionnaire survey approach to collect data from firms belonging to the Spanish automotive industry. Results from a final sample of 64 Spanish automotive firms show that HR practices aimed at motivating and giving employees the opportunity to behave as expected significantly affect knowledge sharing and maintaining. Further, knowledge sharing and maintaining is shown to mediate the relationship between HR practices and knowledge creation. The paper ends with a conclusion, limitations and implications for future research.