Spatial patterns of tropical rainfall are strongly influenced by mountains. Although theories for precipitation induced by convectively stable upslope ascent exist for the midlatitudes, these do not represent the interaction of moist convection with orographic forcing. Here, we present a theory for convective precipitation produced by the mechanical interaction of a tropical ridge with a basic state horizontal wind. Deviations from this basic state are represented as the sum of a `dry' perturbation, due to the stationary orographic gravity wave, and a ‘moist’ perturbation that carries the convective response. The moist component dynamics are subject to the weak temperature gradient approximation; they are forced by the dry mode’s influence on lower-tropospheric moisture and temperature. Analytical solutions provide estimates of the precipitation profile, including peak precipitation, upstream extent, and rain shadow extent. The theory can be used with several degrees of complexity depending on the technique used to compute the dry mode, which can be drawn from linear mountain wave theory or full numerical simulations. To evaluate the theory, we use a set of convection-permitting simulations with a flow-perpendicular ridge in a long channel. The theory makes a good prediction for the cross-slope precipitation profile, indicating that the organization of convective rain by orography can be quantitatively understood by considering the effect of stationary orographic gravity waves on a lower-tropospheric convective quasiequilibrium state.