We combine Homotopy Type Theory with axiomatic cohesion, expressing the latter internally with a version of "adjoint logic" in which the discretization and codiscretization modalities are characterized using a judgmental formalism of "crisp variables". This yields type theories that we call "spatial" and "cohesive", in which the types can be viewed as having independent topological and homotopical structure. These type theories can then be used to study formally the process by which topology gives rise to homotopy theory (the "fundamental $\infty$-groupoid" or "shape"), disentangling the "identifications" of Homotopy Type Theory from the "continuous paths" of topology. In a further refinement called "real-cohesion", the shape is determined by continuous maps from the real numbers, as in classical algebraic topology. This enables us to reproduce formally some of the classical applications of homotopy theory to topology. As an example, we prove Brouwer's fixed-point theorem.