We consider the initial value problems (IVPs) for the modified Korteweg–de Vries (mKdV) equation \(\begin{aligned} \left\{ \begin{array}{l} \partial _t u+ \partial _x^3u+\mu u^2\partial _xu =0, \quad x\in \mathbb {R},\; t\in \mathbb {R}, \\ u(x,0) = u_0(x), \end{array}\right. \end{aligned}\) where u is a real valued function and \(\mu =\pm 1\) , and the cubic nonlinear Schrödinger equation with third order dispersion (tNLS equation in short) \(\begin{aligned} \left\{ \begin{array}{l} \partial _t v+i\alpha \partial _x^2v+\beta \partial _x^3v+i\gamma |v|^2v = 0, \quad x\in \mathbb {R},\; t\in \mathbb {R}, \\ v(x,0) = v_0(x), \end{array}\right. \end{aligned}\) where \(\alpha , \beta \) and \(\gamma \) are real constants and v is a complex valued function. In both problems, the initial data \(u_0\) and \(v_0\) are analytic on \(\mathbb {R}\) and have uniform radius of analyticity \(\sigma _0\) in the space variable. We prove that the both IVPs are locally well-posed for such data by establishing an analytic version of the trilinear estimates, and showed that the radius of spatial analyticity of the solution remains the same \(\sigma _0\) till some lifespan \(0<T_0\le 1\) . We also consider the evolution of the radius of spatial analyticity \(\sigma (t)\) when the local solution extends globally in time and prove that for any time \(T\ge T_0\) it is bounded from below by \(c T^{-\frac{4}{3}}\) , for the mKdV equation in the defocusing case ( \(\mu = -1\) ) and by \(c T^{-(4+\varepsilon )}\) , \(\varepsilon >0\) , for the tNLS equation. The result for the mKdV equation improves the one obtained in Bona et al. (Ann Inst Henri Poincaré 22:783–797, 2005) and, as far as we know, the result for the tNLS equation is the new one.