Wood compounds, especially sterols, are connected with the level of contamination with microscopic fungi. Within this study, tests were conducted on wood dust samples collected at various work stations in a pine and birch timber conversion plant. Their contamination with mycobiota was measured as the concentration of ergosterol (ERG) by ultra performance liquid chromatography (UPLC). Another aim of this study was to assess the effect of contamination with microscopic fungi on the sterol contents in wood dusts. Analyses were conducted on five sterols: desmosterol, cholesterol, lanosterol, stigmasterol, and β-sitosterol using UPLC and their presence was confirmed using gas chromatography/mass spectrometry (GC/MS). The results of chemical analyses showed the greatest contamination with mycobiota in birch wood dust. We also observed varied contents of individual sterols depending on the wood dust type. Their highest concentration was detected in birch dust. The discriminant analysis covering all tested compounds as predictors showed complete separation of all tested wood dust types. The greatest discriminatory power was found for stigmasterol, desmosterol, and ergosterol.