Periodic boundary conditions enable fast density-functional-based calculations for defects and their complexes in semiconductors. Such calculations are popular methods to estimate defect energetics, structural parameters, vibrational modes and other physical characteristics. However, the periodicity introduces spurious defect-defect interactions and dispersion of the defect-induced electronic states. For charged defects, compensating background charging has to be introduced to avoid electrostatic divergences. These factors, together with the intrinsic limitation of standard density-functional theory for accurate estimation of semiconducting gaps, pose challenges for quantitatively accurate and properly controlled calculations. This chapter discusses these issues, including point sampling, electrostatic (Madelung) corrections, valence-band (reference energy) alignment, and other finite-size effects in supercell calculations. These are important for reliable estimation of formation and migration energies as well as ionization-level prediction. Moreover, the chapter discusses the various ways of generating transferable pseudopotentials, the choice of the exchange-correlation functional, and other topics related to total-energy calculations. Methods to calculate excitation energies and other spectroscopic properties as well as atomic motions are also discussed. Examples of applications of the supercell methods to a few selected semiconductor defects are presented.