Maybe if this were the 70s, but this is 2021 and wearing a hat indoors is perfectly normal/acceptable.
It signals that you are uncomfortable, that you intend to leave soon, essentially that you don't enjoy being here with me.
I remember some people being quite insistent that I should take my coat/jacket off, they say something like "make yourself comfortable" but I understand it more as a polite way of saying "take off your coat, you asshole". I guess the same can be said of hats.
Interesting. Never in a million years would I have taken that meaning from it. I would just think that the person is cold.
A hat signifies status. Consider the top hat - it signifies wealth. Or the general's hat - think of Wellington and Napoleon. They signify authority.
It's inappropriate to walk into someone's parlour as a guest, while disporting the mark of your superiority. Baring your head signifies humility. It's just polite.
In the past, maybe. I don't think it does so much now (at least in my part of the US). If it signifies anything besides aesthetics, it's signifying that the person is part of some defined group. Status doesn't enter into it.
> while disporting the mark of your superiority.
So, keeping your "low status" hat on would be OK? (I'm assuming that there is such a thing -- that some hats are "high status" implies that there exists the opposite).
Baring your head is the sign of humility. It doesn't matter which hat you have to doff.
In the UK, a "low status" hat would have been be a flat-hat, or flat cap. It used to be a worker's hat; it was also worn by countrymen - farmers, country landowners, gamekeepers and the like - but not in town.
Nowadays I often see expensive tweed flat-hats on the heads of fashionable, well-to-do townies. To me, that look is poncey.
Besides, the rules about wearing a hat inside can be quite complex: women have to wear a had while men have to take it off (traditional church service in Europe); high ranking men wearing their hats, while lower ranking men have to take them off; petitioners removing their hat in front of the benefactor ...
Romans mostly didn't wear hats.
Jewish men have worn the kippah (small hat) essentially all the time for much of that period. Especially indoors, in a synagogue. It's a symbol of respect for God.
The "take the hat off indoors but always wear it outdoors" certainly hasn't been universal in western Europe for the last 4000 years.
In old times, at least in Europe, discovering yourself was therefore a sign of respect, as it meant voluntarily leaving your guard down in front of someone.
In some Royal courts, that is actually how the king made you a noble, by just saying "you may cover yourself" - only the highest of social ranks was allowed to keep their hat on in front of royalty.
Here in Spain we learn about it because those tropes appear a lot in classic theatre: a person choosing to remain covered in a church is seen as blasfemy, not discovering your cape and hat while passing near a stranger at night is a sign that you are a criminal, etc.
You don't wear a hat in someone's home (or the House Of God, for that matter). And if you want to show respect to someone, you raise your hat (or just tip the brim, if all you're willing to do is go through the motions).
I find that raising my hat tends to cause startled looks. But I still do it.
We don't put shoes on the table, it is considered impolite. The reasoning is simple, shoes can be dirty and you don't want them on the table where you might be eating some time later.
If hats were only worn outside, maybe they were dirty too? I do like the idea that people wore hats because you could expect to have poo flying out of windows and it would fit this context too.
Now whenever I happen to pickup my high school age children and see kids wearing hats in school I'm actually shocked at how "rude" they are being. It is silly.