Magnetically doped topological insulators enable the quantum anomalous Hall effect (QAHE) which provides quantized edge states for lossless charge transport applications [1][2][3][4][5][6][7][8][9]. The edge states are hosted by a magnetic energy gap at the Dirac point[2] but all attempts to observe it directly have been unsuccessful. The size of this gap is considered the clue to overcoming the present limitations of the QAHE, which so far occurs only at temperatures one to two orders of magnitude below its principle limit set by the ferromagnetic Curie temperature T C [8,9]. Here, we use low temperature photoelectron spectroscopy to unambiguously reveal the magnetic gap of Mn-doped Bi 2 Te 3 films which is present only below T C . Surprisingly, the gap turns out to be ∼ 90 meV wide, which not only exceeds k B T at room temperature but is also 5 times larger than predicted by density functional theory [10]. By an exhaustive multiscale structure characterization we show that this enhancement is due to a remarkable structure modification induced by Mn doping. Instead of a disordered impurity system, it forms an alternating sequence of septuple and quintuple layer blocks, where Mn is predominantly incorporated in the center of the septuple layers. This self-organized heterostructure substantially enhances the wave-function overlap and the size of the magnetic gap at the Dirac point, as recently predicted [11]. Mn-doped Bi 2 Se 3 forms a similar heterostructure, however, only a large, albeit nonmagnetic gap is formed. We explain both differences based on the higher spin-orbit interaction in Bi 2 Te 3 with the most important consequence of a magnetic anisotropy perpendicular to the films, whereas for Bi 2 Se 3 the spin-orbit interaction it is too weak to overcome the dipole-dipole interaction. Our findings provide crucial insights for pushing the lossless transport properties of topological insulators towards room-temperature applications.We thank B. Henne, F. Wilhelm, and A. Rogalev for support of the XANES and EX-AFS measurements at ID 12 and BM23 beam lines of the ESRF, V. Holý for advices on the structure model, W. Grafeneder for the TEM sample preparation and G. Bihlmayer and A. Ernst for helpful discussions. S.A.K and J.M. are grateful for support from CEDAMNF (CZ.02.1.01/0.0/0.0/15 003/0000358) of Czech ministry MSMT.