We can always question whether we’re using the right conditional word, even if it’s grammatically correct.
In many cases, if and whether can be used interchangeably. But there is a time and place where each one serves its own purpose more effectively. These discrepancies (although not a major mistake and often overlooked) still have the power to make some editors cringe.
If and whether are used to introduce or compare either unknown factors or future plans.
If is used more so when asking a question, or in more casual instances.
Whether is used more so in a statement or reflection of the said question (as commentary, for example), or in more formal instances.
See the differences in the following examples:
I don’t know if I should get chocolate or vanilla ice cream.
The boy was unsure whether to get vanilla or chocolate ice cream.
What if there is no ice cream left by the time we get there?
We weren’t sure whether there would be any ice cream left over by the time we got there.