As well as thinking about your own moves, it's vitally important to keep an eye on what your opponent is up to as well. Many players make the mistake of focusing only on their own plans and paying no attention to their opponent's possibilities until it's too late. Don't fall into this trap - after every move take stock of what your opponent just did, and what they might do next. Only if there is no threat (or the threat isn't great enough to concern you) should you carry on with your own plans.
After every move by your opponent, you need to ask yourself:
Let's take a look at each question in more detail.
Just as we need to make sure we aren't moving our pieces onto unsafe squares, we also need to check after every move by the opponent that they haven't just attacked one of our pieces. Sometimes this is very straightforward, as in the following example.
In addition to threats from the piece that has just moved, we also need to look at what lines have been unblocked by the opponent's move. A line may have been opened for one of our opponent's pieces to threaten one of ours. This is called a discovered attack.
It isn't enough to just check if the piece our opponent moved is doing any harm on it's current square - we also need to take a look where it might go next. This is especially important to do if we have lots of loose pieces lying around!
Of course, we shouldn't expect every move by our opponents to be a source of immediate danger - they are human beings too and will make mistakes as well (especially if they don't remember to ask themselves these questions every turn!). You should always try to be on the lookout for slip ups by your opponent and see if you can punish them for it. Even if you can't fathom the purpose of your opponent's last move, don't be intimidated into assuming it must be part of some deep plan. Sometimes your opponent's moves do carry a threat, but you can ignore it if your threat is the greater. See the next board for an example.