R package BayesGESM: Bayesian Analysis of Generalized Elliptical Semi-Parametric Models and Flexible Measurement Error Models. Set of tools to perform the statistical inference based on the Bayesian approach for regression models under the assumption that independent additive errors follow normal, Student-t, slash, contaminated normal, Laplace or symmetric hyperbolic distributions, i.e., additive errors follow a scale mixtures of normal distributions. The regression models considered in this package are: (i) Generalized elliptical semi-parametric models, where both location and dispersion parameters of the response variable distribution include non-parametric additive components described by using B-splines; and (ii) Flexible measurement error models under the presence of homoscedastic and heteroscedastic random errors, which admit explanatory variables with and without measurement additive errors as well as the presence of a non-parametric components approximated by using B-splines.