In these lectures we review Generalized Complex Geometry and discuss two main applications to string theory: the description of supersymmetric flux compactifications and the supersymmetric embedding of D-branes. We start by reviewing G-structures, and in particular SU(3)-structure and its torsion classes, before extending to Generalized Complex Geometry. We then discuss the supersymmetry conditions of type II supergravity in terms of differential conditions on pure spinors, and finally introduce generalized calibrations to describe D-branes. As examples we discuss in some detail AdS4 compactifications, which play a role as the geometric duals in the AdS4/CFT3-correspondence.www.fp-journal.org P. Koerber: Lectures on generalized complex geometry for physicists 1.2 Invitation: supersymmetry conditions in the fluxless case As a warm-up we will study the conditions for unbroken supersymmetry in compactifications without fluxes and see how the condition for a Calabi-Yau geometry comes about. This is also excellently reviewed in a lot more detail in [28, Chap. 15].The bosonic sector of type II supergravity (see appendix B for a brief review) contains, next to the metric and the dilaton, a bunch of form fields, which come from both the NSNS-and the RR-sector of string theory. Putting the vacuum expectation values of these fields -the so-called fluxes -to zero, it turns out that a state with some unbroken supersymmetry solves the equations of motion. This is well-known for theories with global supersymmetry, where the Hamiltonian can be written as a sum of squares and possibly a topological term. The squares vanish precisely when there is unbroken supersymmetry so that the supersymmetric configuration is a global minimum within its topological class (since the topological term does not vary within this class). The statement is more subtle for local supersymmetry, but it still holds for supergravity in the fluxless case. For the case with fluxes we will provide the exact statement in Sect. 4 (Theorem 4.1). The bottom line is that one can construct solutions to the full supergravity equations of motion by solving the relatively simpler supersymmetry conditions. Let us proceed with such fluxless compactifications to 4D Minkowski space. This means we split the total 10D space-time in a 4D uncompactified part with flat Minkowski metric and an internal part with -to be determined -curved metric. Then we follow the strategy of constructing solutions by imposing unbroken supersymmetry. This means that there must be some fraction of the supersymmetry generators for which the supersymmetry variations of all the fields vanish.It turns out that the variations of the bosonic fields always contain a fermionic field. Therefore, if we put the vacuum expectation values of all the fermionic fields to zero in our background, the variations of the bosonic fields automatically vanish. In fact, we must put the vacuum expectation values of all fermionic fields to zero, since they would not be compatible with the compactification ansatz, which ...