In this review we provide an organized summary of the theoretical and computational results which are available for polymers subject to spatial or topological constraints. Because of the interdisciplinary character of the topic, we provide an accessible, non-specialist introduction to the main topological concepts, polymer models, and theoretical/computational methods used to investigate dense and entangled polymer systems. The main body of our review deals with: (i) the effect that spatial confinement has on the equilibrium topological entanglement of one or more polymer chains and (ii) the metric and entropic properties of polymer chains with fixed topological state. These problems have important technological applications and implications for the life-sciences. Both aspects, especially the latter, are amply covered. A number of selected open problems are finally highlighted.