Why does my iPhone 5s get so hot whenever I'm not at my house and how to I stop it?

Like when I go to school, I feel it heating in my pocket. Even when Wi-Fi isn't on or apps are running, it still gets hot. I always have to end up restarting my iPhone, which is frustrating because it takes like 1-3 minutes for it to turn back on.

Something might be wrong with the battery.

Take it to the apple store. If it was charging, then that would be a different story.

It could be a firmware issue or a battery issue too. You can hard reset the phone and see if that helps. If not, you can get the battery changed.