A comprehensive, five-dimensional calculation of Higgs-boson production in gluon fusion is performed for both the minimal and the custodially protected RandallSundrum (RS) model, with Standard Model fields propagating in the bulk and the scalar sector confined on or near the IR brane. For the first time, an exact expression for the gg → h amplitude in terms of the five-dimensional fermion propagator is derived, which includes the full dependence on the Higgs-boson mass. Various results in the literature are reconciled and shown to correspond to different incarnations of the RS model, in which the Higgs field is either localized on the IR brane or is described in terms of a narrow bulk state. The results in the two scenarios differ in a qualitative way: the gg → h amplitude is suppressed in models where the scalar sector is localized on the IR brane, while it tends to be enhanced in bulk Higgs models. In both cases, effects of higher-dimensional operators contributing to the gg → h amplitude at tree level are shown to be numerically suppressed under reasonable assumptions. There is no smooth cross-over between the two scenarios, since the effective field-theory description breaks down in the transition region. A detailed phenomenological analysis of Higgs production in various RS scenarios is presented, and for each scenario the regions of parameter space already excluded by LHC data are derived.