We present a linear stability analysis of density-driven miscible flow in porous media in the context of carbon dioxide sequestration in saline aquifers. Carbon dioxide dissolution into the underlying brine leads to a local density increase that results in a gravitational instability. The physical phenomenon is analogous to the thermal convective instability in a semi-infinite domain, owing to a step change in temperature at the boundary. The critical time for the onset of convection in such problems has not been determined accurately by previous studies. We present a solution, based on the dominant mode of the self-similar diffusion operator, which can accurately predict the critical time and the associated unstable wavenumber. This approach is used to explain the instability mechanisms of the critical time and the long-wave cutoff in a semi-infinite domain. The dominant mode solution, however, is valid only for a small parameter range. We extend the analysis by employing the quasi-steady-state approximation (QSSA) which provides accurate solutions in the self-similar coordinate system. For large times, both the maximum growth rate and the most dangerous mode decay as , respectively. The instability problem is also analysed in the nonlinear regime by high-accuracy direct numerical simulations. The nonlinear simulations at short times show good agreement with the linear stability predictions. At later times, macroscopic fingers display intense nonlinear interactions that significantly influence both the front propagation speed and the overall mixing rate. A dimensional analysis for typical aquifers shows that for a permeability variation of 1—3000 mD, the critical time can vary from 2000 yrs to about 10 days while the critical wavelength can be between 200 m and 0.3 m.