When talking about (subjective) feelings or opinions, we like to use certain dative constructions such as Mir ist kalt. In this case, we use this because we want to express our personal feeling in regards to the temperature. There are other cool dative constructions like this. Check it out!
Ich finde/denke, Kochen ist unterhaltsam.
Kochen macht mir Spaß.
Ich finde/denke, Pizza ist lecker.
Pizza schmeckt mir.
Ich finde/denke, Deutsch ist super.
Deutsch gefällt mir.
Those are way shorter, I like it.
Useful, right? These dative constructions are used all the time. Take a closer look:
The sentences should be translated as:
Cooking is fun.
I like pizza.
I like German.
But what we are literally saying is:
Oh! Is that why my German friends say something makes a lot of fun?
Yes, it's a common mistake. Here are some more:
Ich bin kalt. → I'm a cold person.
Mir ist kalt. → I am/feel cold.
Ich bin schlecht. → I'm bad/a bad person.
Mir ist schlecht. → I feel bad/sick.
Ich tut der Kopf weh. → doesn't exist
Mir tut der Kopf weh. → My head hurts.
Grammar for nerds:
Did you notice the verb in those sentences? The subject in the dative sentences is es (sometimes only implicitly), not the person in question.
We also have "dummy subjects" in English. Yes, this is what linguists call them!
"It" doesn't really mean anything, but it is the subject of the sentence and therefore we need the -s in the verb → the he/she/it-conjugation.
When you start your sentence with mir/dir/ihr/... , make sure the verb is conjugated in the third person singular, the er/sie/es-conjugation.