Foreigners who do not leave Thailand by the expiration date of their permission to stay, as stated by the visa or entry stamp, are considered to be in the country illegally and will be sanctioned. They must pay a fine 500 Baht per day of overstay (up to 20,000 Baht) when leaving Thailand.
To avoid paying the fine, the application to extend the visa must be made no later than the next working day after the visa expired.

A short-term visa that has expired can be extended after the fine for overstay is paid, but the extension period granted is reduced by the number of days of overstay.

Overstaying for more than 90 days is considered a serious offence and the person may be incarcerated before being deported. They also will be banned from visiting Thailand for a period depending on the length of the overstay.
In case of repeated violations of overstaying, the foreigner’s passport can be stamped which can make obtaining entry to other countries much harder than usual.