It is used in writing to indicate an afterthought or an additional note that is added after the main part of the text is complete.
In everyday usage, PS is often used informally as a way to add something to a letter, email, or text message.