We consider (M, g) a smooth compact Riemannian manifold of dimension n ≥ 2 without boundary, 1 < p a real parameter and r = p(n+p) n . This paper concerns the validity of the optimal Moser inequalityThis kind of inequality was already studied in the last years in the particular cases 1 < p < n. Here we solve the case n ≤ p and we introduce one more parameter 1 ≤ τ ≤ min{p, 2}. Moreover, we prove the existence of an extremal function for the optimal inequality above. 1 Introduction Optimal inequalities of Moser [22] type have been extensively studied both in the Euclidean and Riemannian contexts. We refer the reader to [1], [2], [3], [11], [13] for the Euclidean case and to [5], [7], [8], [10] for Riemannian manifolds.In 1961, Moser [22] proved that solutions of certain elliptic equations of second order have the standard L ∞ norm dominated by the standard L p norm for all p > 1. This technique has been improved and is now known as Giorgi-Nash-Moser, which plays an important role in the theory of PDEs. The idea developed by Moser to prove that increase is based on an iteration process. The key point of this technique in [22] consists in connecting the solution a particular PDE to inequality: * 2010 Mathematics Subject Classification: 58J05, 53C21 †