Motivated by problems in certain areas of analysis, like measure theory and harmonic analysis, where σ-ideals of compact sets are encountered very often as notions of small or exceptional sets, we undertake in this paper a descriptive set theoretic study of σ-ideals of compact sets in compact metrizable spaces. In the first part we study the complexity of such ideals, showing that the structural condition of being a σ-ideal imposes severe definability restrictions. A typical instance is the dichotomy theorem, which states that σ-ideals which are analytic or coanalytic must be actually either complete coanalytic or else G_δ. In the second part we discuss (generators or as we call them here) bases for σ-ideals and in particular the problem ...