I’ve been seeing a lot confusion over the difference between like and as if lately. I used to see it all the time when I was teaching Freshman Composition, but I also find it in creative writing submitted to Prime Number Magazine and also in the stories in my fiction workshops.
Mostly I know which to use by ear, but there’s a grammar-based reason behind the usage, and it’s not complicated. Like is a preposition. As (or as if or as though) is a conjunction. Use like if it is followed by noun/object. Use as if it is followed by a verb/clause.
She ran like the wind. Here, like is a preposition followed by its object, the wind.
She ran as if the devil were right behind her. Here, as if is followed by a verb (actually a clause: the devil were right behind her). (We would NOT say “she ran like the devil were right behind her.”)
That’s pretty clear, right? According to Garner’s Modern American Usage, the use of like as a conjunction was considered nonstandard through the mid-20th century. But it is used that way in speech, often, and so now it is considered informal. Garner says: “Although this use of like can no longer be considered an outright solecism, as it once was, it hasn’t moved far from the borderline of acceptability. It is acceptable casual English; it isn’t yet in the category of unimpeachable English.”
In writing then, unless you are trying to reflect colloquial usage, it’s advisable to make the distinction.
Here’s some more on the subject: Grammar Girl.