About a quarter of all post-asymptotic giant branch (AGB) stars are hydrogen-deficient. Stellar evolutionary models explain the carbon-dominated H-deficient stars by a (very) late thermal pulse scenario where the hydrogen-rich envelope is mixed with the helium-rich intershell layer. Depending on the particular time at which the final flash occurs, the entire hydrogen envelope may be burned. In contrast, helium-dominated post-AGB stars and their evolution are yet not understood. A small group of very hot, helium-dominated stars is formed by O(He)-type stars. We performed a detailed spectral analysis of ultraviolet and optical spectra of four O(He) stars by means of state-of-the-art non-LTE model-atmosphere techniques. We determined effective temperatures, surface gravities, and the abundances of H, He, C, N, O, F, Ne, Si, P, S, Ar, and Fe. By deriving upper limits for the mass-loss rates of the O(He) stars, we found that they do not exhibit enhanced mass-loss. The comparison with evolutionary models shows that the status of the O(He) stars remains uncertain. Their abundances match predictions of a double helium white dwarf merger scenario, suggesting that they might be the progeny of the compact and of the luminous helium-rich sdO-type stars. The existence of planetary nebulae that do not show helium enrichment around every other O(He) star, precludes a merger origin for these stars. These stars must have formed in a different way, for instance via enhanced mass-loss during their post-AGB evolution or a merger within a common-envelope (CE) of a CO-WD and a red giant or AGB star. A helium-dominated stellar evolutionary sequence exists, that may be fed by different types of mergers or CE scenarios. It appears likely, that all these pass through the O(He) phase just before they become white dwarfs.