Metabolomics has been shown to be an effective tool for disease diagnosis, biomarker screening and characterization of biological pathways. A total of 140 subjects were included in this study; urine metabolomes of patients with liver cirrhosis (LC, n=40), patients with hepatocellular carcinoma (HCC; n=55) and healthy male subjects (n=45) as a control group were studied. Gas chromatography/mass spectrometry-based urine metabolomics profiles were investigated for all participants. Diagnostic models were constructed with a combination of marker metabolites, using principal components analysis and receiver operator characteristic curves. A total of 57 peaks could be auto-identified of which 13 marker metabolites (glycine, serine, threonine, proline, urea, phosphate, pyrimidine, arabinose, xylitol, hippuric acid, citric acid, xylonic acid and glycerol) were responsible for the separation of HCC group from healthy subjects. Also, eight markers metabolites (glycine, serine, threonine, proline, citric acid, urea, xylitol and arabinose) showed significant differences between the LC group and healthy subjects. No significant difference was detected between HCC and LC groups regarding all these metabolites. Metabolomic profile using GC-MS established an optimized diagnostic model to discriminate between HCC patients and healthy subjects; also it could be useful for diagnosis of LC patients. However, it failed to differentiate between HCC and LC patients.