Ash Shaykh Al Uthaymeen mentions a principle in Sharhul Mumtia 2/151

“The legislative principle is:

Every obligatory act in worship is a condition for its correctness.

Thus if a person leaves it off on purpose, then this [specific] act of worship is invalid.

For this reason if a person leaves off the first Tashahud or the last one in the prayer on purpose, then his prayer is invalid.

Similarly the rest of the obligatory acts; if he leaves it off on purpose, his prayer is invalid.

For that reason we say:

Covering the Awrah is a condition for the correctness of the prayer.

The one that prays without wearing that which covers his Awrah, or that which is considered correct that it is obligatory to be covered, then his prayer is invalid.

Ibn Abdul Bar relayed the consensus of the scholars that the one who prays naked whilst he is able to wear clothing, then his prayer is invalid.

Similarly shaykhul Islam Ibn Taymiyah relayed that the scholars agree that the individual who prays naked whilst he is able to wear clothing than his prayer is invalid.”

End quote.

Translated by

Majid Jawed Al-Afghanee
Abu Layl