When one makes the intention to perform an iʿtikāf that is not an assigned obligation,[1] he can stipulate a condition from the outset that if a problem arises, he will leave the iʿtikāf.[2] Therefore, by stipulating such a condition, one can leave the iʿtikāf if a problem arises, and there is no problem in doing so even on the third day.
However, if a muʿtakif stipulates a condition that he will stop his iʿtikāf even if no particular reason arises, the validity of such a condition is problematic [i.e. based on obligatory precaution, it is not a valid condition]. It is worth mentioning that stipulating the aforementioned condition (i.e.
the condition of leaving the iʿtikāf in the middle of it if a problem arises) before or after the iʿtikāf has started is not correct; rather, it must be stipulated at the time of making the intention to perform iʿtikāf.