WordPress saves revisions of your posts as you edit. This may not be obvious to you. With a post open for editing, click the “Screen Options” dropdown in the upper right of your screen and check the box for “Revisions”. If you don’t see it, you are probably looking at a post with no revisions. Once on, it is a sticky setting so you should always see the revisions section at the bottom of the page when editing posts.
To go back to a prior revision, click the link next to the revision you want, compare the revision to the current version and click the “Restore This Revision” button if you really want to go back to the revision.
This can be a lifesaver if you’ve broken some complex HTML or lost some important content inadvertently!