Both of the phrases you provided can be correct, depending on the context in which they are used.
"Why you are sad?" - This is a statement with a question mark at the end, and it is more commonly used in informal or casual speech. It is sometimes referred to as "wh-movement," where the question word "why" moves to the beginning of the sentence. For example, if someone sees you looking sad and they want to inquire about the reason, they might ask, "Why you are sad?" However, it's essential to note that this form is not considered grammatically correct in formal writing or standard English.
"Why are you sad?" - This is the standard, grammatically correct form of the question in English. The subject ("you") is followed by the auxiliary verb ("are"), and then the question word "why" introduces the reason for the person's sadness. This is the form you should use in most situations, both in spoken and written English.
To summarize, "Why are you sad?" is the more appropriate and widely accepted form to use. "Why you are sad?" may be heard in informal speech or certain dialects but is not considered grammatically correct in standard English.