A new large class of rearrangement-invariant (symmetric) spaces is introduced which contains most classical spaces used in applications. It consists of spaces with arbitrary fundamental function $\f(t)$ which are interpolation spaces with respect to the corresponding extreme spaces $\Lambda_\varphi$ and $M_\varphi$ (the quasinorm case is also permitted). The (quasi)norms for these new spaces are of the form $\|\varphi(t)f^*(t)\|_{\widetilde E}$, where $\widetilde E$ is an arbitrary rearrangement-invariant function space with respect to the measure $dt/t$. Thus the considered spaces include and generalize Lorentz, Lorentz–Zygmund and other similar spaces as well as the spaces $L_{p,\alpha, E}$, previously studied by Pustylnik. In spite of their generality, these spaces can be investigated deeply and in detail with rather sharp results that open a simple way to various applications, extending results about their classical examples. For instance, their dual spaces, sharp conditions for separability and mutual embeddings, dilation functions, Boyd indices and so on are found. A theorem on optimal weak type interpolation in these spaces is also proved.