An electromagnetic theory of thermal radiation is outlined, based on the fluctuation electrodynamics of Rytov and co-workers. We discuss the basic concepts and the status of different approximations. The physical content is illustrated with a few examples on near-field heat transfer.