The invention relates to an apparatus for determining a number of beams in IMRT. An objective function providing unit (13) provides an objective function of an IMRT procedure, wherein the objective function depends on a target dose to be applied during the IMRT procedure. A sensitivity determination unit (14) determines the sensitivity of the objective function with respect to changes of the target dose, and a beam number determination unit (15) determines the number of beams depending on the determined sensitivity. It has been found that the sensitivity of the objective function with respect to changes of the target dose is an accurate measure for reliably determining an optimized number of beams in IMRT, which allows for generating a high quality treatment plan and which in turn leads to an improved IMRT procedure.