When you grab a phone and start dialing, should you specify the area code? The correct answer depends on far too many factors.
Are you using a cell phone? If so, the answer is easy: always yes, even if the other number is right next to you, on the same provider as you, with the same exchange as you, on the same plan as you, even on the same account as you. This seems an inconvenience, but it's not really, compared to the alternative.
Otherwise, the answer depends on whether the exchange happens to be local to you, a factor which can't be told by looking at the number, unless you have a list memorized which is long, changes every few years, and becomes increasingly confusing with the addition of cell phones that are not so geographically linked.
But the real problem is that the system gives you an error if you provide it information it doesn't need, by including the area code when it's not required. It should be considered optional. That way, you could just dial it all if you aren't sure if the exchange is local, and it would always work. But the stupid phone system throws an error instead of connecting the call just because you provided correct but superfluous information, by dialing the area code on a call that turns out to be local.
If it wasn't like this and someone suggested making it that way, you would consider it a bug. Maybe when switch systems were physical switches, there was some reason for this, but that's not been the case for ages. When I have to use a land line, I seem to get it wrong almost every time I dial an unfamiliar number. It turns out to be a cell phone that is inexplicably local despite the owner living in one remote area, and being currently located in another remote area. Or it turns out that a number that is a short drive away happens to be across some arbitrary boundary, but I didn't include the area code because I didn't want the extra delay of the "area code not required" error and having to start over.
There's no real excuse for this. We just put up with it because it's always been this way. Stupid phone company. Graaahhhr.