Three-dimensional printing (3DP) has attracted a considerable amount of attention during the past years, being globally recognized as one of the most promising and revolutionary manufacturing technologies. Although the field is rapidly evolving with significant technological advancements, materials research remains a spotlight of interest, essential for the future developments of 3DP. Smart polymers and nanocomposites, which respond to external stimuli by changing their properties and structure, represent an important group of materials that hold a great promise for the fabrication of sensors, actuators, robots, electronics, and medical devices. The interest in exploring functional materials and their 3DP is constantly growing in an attempt to meet the ever-increasing manufacturing demand of complex functional platforms in an efficient manner. In this review, we aim to outline the recent advances in the science and engineering of functional polymers and nanocomposites for 3DP technologies. The report covers temperature-responsive polymers, polymers and nanocomposites with electromagnetic, piezoresistive and piezoelectric behaviors, self-healing polymers, light- and pH-responsive materials, and mechanochromic polymers. The main objective is to link the performance and functionalities to the fundamental properties, chemistry, and physics of the materials, and to the process-driven characteristics, in an attempt to provide a multidisciplinary image and a deeper understanding of the topic. The challenges and opportunities for future research are also discussed.