The dependence of impurity transport on plasma parameters in the modular stellarator Wendelstein 7-AS was investigated by means of a laser blow-off technique. An increased impurity transport at higher heating power and lower magnetic field strength as well as no effect of the isotope composition on the impurity confinement was observed. The most critical scaling with respect to stationary operation at high density is the improved confinement of impurities at high densities, leading to a degradation of plasma energy by increasing radiation and to a loss of density control. This was attributed to a reduction of the impurity diffusion coefficient with density. After installation of island divertor modules, a transition from normal confinement into the high-density H-mode (HDH) at a certain power-dependent threshold density appeared. This transition is characterized by a strong reduction of the impurity confinement time and an increase in energy confinement time. In the HDH operational regime, access to even higher densities (4 × 1020 m-3) than achieved before became possible under stationary operation conditions. Impurity transport measurements and model predictions indicate that the reduction of the impurity confinement in HDH is caused by not only a reduction of the inward convection in the core plasma but also possibly by changes in the edge transport. Comparison of experimental data with an axisymmetric transport model should elucidate the role of stellarator-specific transport aspects.