We're used to seeing raw files that are 20–50MB and JPEG files that are less than 2MB, so it’s common to think that is a “normal” range of file size, and that hundreds of MB are "excessive." But actually, the natural file size of an image is as Johan described, when you calculate the number of pixels, bits, and channels. Raw and JPEG can be smaller due to the compromises below.
Raw files are smaller because they are only one channel of unprocessed sensor data, at maybe 10 to 16 bits depending on the camera. The expansion from one sensor data channel to three RGB channels automatically triples the size. The size can go up some more if the bit depth goes up too, such as if the camera recorded at 10 bits per channel and it was converted to 16 bits per channel (and into three channels).
That expansion to RGB is necessary because if an application doesn’t edit raw files directly, the single channel raw file must be expanded to three RGB (or four CMYK) channels. Photoshop needs that because it can’t edit raw files directly, that is why it relies on Camera Raw or Lightroom to do the conversion to RGB. So the conversion, and the expanded file size, are unavoidable if going to Photoshop or any other non-raw photo editor.
And of course the compromise that lets JPEG files be so small is that JPEG uses lossy compression, losing a lot of the original data.