A topos (plural topoi, toposes) is a category that behaves like the category of sheaves of sets on a topological space. Topos theory consists of the study of Grothendieck topoi, used in algebraic geometry, and the study of elementary topoi, used in logic.
Topos theory has developed from the study of sheaves. Sheaves arose in geometry as coefficients for cohomology and as descriptions of the functions appropriate to various kind of manifolds (algebraic, analytic, etc.). Sheaves also appear in logic as carriers for models of set theory as well as for the semantics of other types of logic.
Grothendieck introduced a topos as a category of sheaves for algebraic geometry. Subsequently, Lawvere and Tierney obtained elementary axioms for such (more general) categories.