Sorry to butt in, but I think what iefan means is that the formula is E²=(mc²)²+(pc)².
E=mc² is only a special case of that: when an object is not moving relative to you and it has mass.
Light has no mass. And that’s why the special case for that is E=pc.
So no, E=mc² doesn’t always hold true. Unfortunately physicists have failed to explain that clearly to us laypeople. Alas, much lamenting among them about this confusion…