https://www.italki.com/#/question/85474 -- ................
正直に言えば、日本人は外国人に「日本語がお上手ですね」と言ってどういう意味でしょうか?
相手は本当に上手でも、ちょっとだけ話せても言われるから、真正の意味はあまり分からないかもしれません。僕は初めて日本人に会う時、いつもそれを言われていますが、実は なんか ちょっと馬鹿にされていると感じるようになります。 ............
( I love this last ようになります。-- the responses are good too. )
i think often it's another way of saying -- [ I'm very happy (or glad or pleased) that a you (a non-Jp person) are studying Japanese. ]
Often a genuine 「日本語 お上手ですね」 is prompted by, e.g. :
--- Using both 手前 and 前 while differentiating them correctly
--- Using a difficult word or construction correctly, or exactly at the appropriate context.
--- Using a word or construction that this native Jp person feels is uniquely Japanese -- and i don't mean Wabi, Sabi, Mono no Aware, etc.