The sensors and data acquisition universal interface provide more powerful choices for experimental teaching. In this paper, we introduce a teaching experimental setup that uses current and voltage sensors combined with universal interface to realize real-time automatic measurement of solar cell current–voltage characteristics. The current–voltage (I–V) and power–voltage (P–V) curves at various distances from the light source can be easy and fast obtained. At the same time, the effect of temperature on the electrical performance of photovoltaic modules can also be directly demonstrated using the cooling fan. Compared with the data read by ammeter and voltmeter, the experimental setup we built can enable students to obtain data faster under the same experimental conditions. We suggest that the real time I–V and P–V curves can help students experiment with the output characteristics of solar cells directly and allow them to relate electrical concepts such as short-circuit current, open-circuit voltage and maximum output power to the operation of the solar cells.