Some apps may show you what you're looking for, but I'm going to explain to you how to use two helpful tools to see your iPhone's temperature, the infrared thermometer and the thermal camera.
With this tool, you can measure the temperature at different spots on your iPhone such as ones that heat up most (battery, screen, CPU and camera sensors).
How to use it
Start by turning on both your infrared thermometer and you iPhone. Then, point the thermometer towards the wanted spots and slowly move the thermometer around the phone to measure temperature at desired places. Don't forget to cover the whole parts you want to measure to get the overall temperature (i.e. whole screen).
The thermal camera (also known as thermal imaging camera or TIC) works similarly to the infrared thermometer but it shows a more accurate temperature measurement and temperature visualization with hot/cold colors. It basically renders infrared radiation as visible light.
How to use it
First, turn on both your thermal camera and your iPhone. Then, point the camera towards the wanted spots to know their temperature. You'll also see which parts of the iPhone are the hottest by looking at the thermal image produced.
Of course, both those tools aren't available for free but I've seen some reasonable offers online (to me).
If you're worried about your iPhone overheating, check out If your iPhone or iPad gets too hot or too cold for what to do.