ものではないOne should not
This construction advises against an action by presenting it as contrary to common sense, morality, or proper conduct—not merely as a bad choice in one particular situation.
A rule about conduct
ものではない treats the advice as a broad principle: this is not how people ought to behave. It is especially natural with conduct involving trust, manners, promises, safety, or harm to others.
General admonitions
Caring advice
体がつらいときに、無理を重ねるものではないよ。
You shouldn't keep pushing yourself when you are physically unwell.
AnalyzeThe sentence is caring, but it still frames the warning as a general principle rather than a quick suggestion for tonight.
General norm versus practical advice
ものではない gives a broad judgment about acceptable conduct. For a practical recommendation tied to the present circumstances, ないほうがいい is normally lighter and more natural.
明日は早いから、今夜はあまり夜更かししないほうがいい。
You'd better not stay up too late tonight, since you have an early start tomorrow.
AnalyzeThis is situation-specific advice, not a moral judgment about staying up late in general.
More examples
人から借りた物を乱暴に扱うものではない。
One should not treat borrowed things carelessly.
Analyze困っている人を見て見ぬふりをするものではない。
One should not pretend not to notice someone in trouble.
Analyze一度の失敗で、自分には才能がないと決めつけるものではない。
You should not conclude from one failure that you have no talent.
Analyze冗談でも、人を傷つけるようなことを言うものではない。
Even as a joke, one should not say things that hurt people.
Analyze親しい間柄でも、相手の秘密を勝手に話すものではない。
Even between close friends, one should not reveal the other person's secrets without permission.
Analyze感情に任せて大切な決断をするものではない。
One should not make important decisions on impulse.
Analyze