Bacterial infection of the lower respiratory tract frequently occurs in mechanically ventilated patients and may develop into life-threatening conditions. Yet, existing diagnostic methods have moderate sensitivity and specificity, which results in the overuse of broad-spectrum antibiotics administered prophylactically. This study aims to evaluate the suitability of volatile bacterial metabolites for the breath-based test, which is used for diagnosing Ventilation-Associated Pneumonia (VAP). The in vitro experiments with pathogenic bacteria most prevalent in VAP etiology (i.e., Acinetobacter baumannii, Escherichia coli, Klebsiella pneumoniae, and Pseudomonas aeruginosa) were performed to identify bacteria-derived metabolites using a specially designed cultivation system enabling headspace sampling for GC-MS analysis. Thirty-nine compounds were found to be significantly metabolized by tested species and, therefore, selected for monitoring in the exhaled breath of critically ill, mechanically ventilated (MV) patients. The emission of volatiles from medical respiratory devices was investigated to estimate the risk of spoiling breath results with exogenous pollutants. Bacterial metabolites were then evaluated to differentiate VAP patients from non-infected MV controls using Receiver Operating Characteristic (ROC) analysis, with AUC, sensitivity, and specificity calculated. Nine bacterial metabolites that passed verification through a non-parametric ANOVA test for significance and LASSO penalization were identified as key discriminators between VAP and non-VAP patients. The diagnostic model achieved an AUC of 0.893, with sensitivity and specificity values of 87% and 82.4%, respectively, being competitive with traditional methods. Further validation could solidify its clinical utility in critical care settings.