Introduction -- Free Klein-Gordon fields on Minkowski spacetime -- Fock quantization on Minkowski space -- CCR algebras and quasi-free states -- Free Klein-Gordon fields on curved spacetimes -- Quasi-free states on curved spacetimes -- Microlocal analysis of Klein-Gordon equations -- Hadamard states -- Vacuum and thermal states on stationary spacetimes -- Pseudodifferential calculus on manifolds -- Construction of Hadamard states by pseudodifferential calculus -- Analytic Hadamard states and Wick rotation -- Hadamard states and characteristic Cauchy problem -- Klein-Gordon fields on spacetimes with Killing horizons -- Hadamard states and scattering theory -- Dirac fields on curved spacetimes.