We present an analytical study of the dynamical local-field factors associated with the response of a homogeneous two-dimensional interacting electron liquid as functions of momentum, frequency, and density. We derive sum rules that constrain their asymptotic forms ͑in momentum and frequency͒ for both the spinsymmetric and spin-antisymmetric cases. Parametrized expressions for the local-field factors are proposed, based on all available sum rules and on many-body perturbation theory, and these are found to be in good agreement with quantum Monte Carlo calculations. Finally, these expressions are used to evaluate the effective electron-electron interaction in a local approximation for two-dimensional systems. It is shown that both the quantitative and qualitative behaviors of the interaction are sensitive to the inclusion of dynamical correlations.