A new low-frequency CW RF gun was developed and tested at Budker Institute of Nuclear Physics recently. We plan to use it to upgrade the ERL of the Novosibirsk FEL facility. It will allow increasing the average beam current (due to higher beam repetition rate) and thus increasing the average radiation power. The transport beamline for the RF gun uses the ninety-degree achromatic bend. It is designed in a way that keeps an option to operate with the old electrostatic gun as well. Due to the low beam energy (290 keV) the beam dynamics is strongly influenced by space-charge forces. The paper describes results of simulation and optimization of the RF gun transport beamline. Space-charge forces were taken into account with the code ASTRA. Main sources of emittance degradation were considered in order to decrease their influence during the optimization. In addition, the RF gun output beam parameters were measured for various RF gun emission phases. These experiments were simulated, and the results were compared. The resulting beam parameters meets requirements of the Novosibirsk FEL facility ERL.