The Feynman diagram technique has proved to be extremely useful in improving perturbational methods in the quantum field theory, as well as in the equilibrium theory of many-body systems. In this chapter we want to describe the special diagram technique introduced by Keldysh for the non-equilibrium Green functions. This technique follows closely the technique introduced formerly into he theory of equilibrium Green functions at zero temperature. Therefore, first we want to outline here the formalism of equilibrium Green functions in the many-body problem, already the subject of so many books in the literature.