Because meg is part of "tar av" You take the socks off of yourself. The sentence does not specify who's socks you're taking off, it specifies who you're talking the socks off of.
If you were to say "Jeg tar av meg sokkene hans", that would be "I take his socks (off of me)"
Hmm... but wouldn
t it be more accurate to translate it with "I take off the socks"? I could also take off someone elses socks that I was borrowing...
In Norwegian, it is often assumed that we're talking about our own something(s) when nothing else is specified, rendering the possessive unnecessary in many cases where it would required, or at least natural, in English.
Your translation is definitely a possible one, but not the most likely one for this sentence.
You need to specify whose socks you're taking off. In the Norwegian sentence, this is specified with the reflexive pronoun "meg". In English this is specified with the possessive "my".