I've been wondering for a while about this.
Why do people do it? I mean, if you use an online wallet, it way safer that having it stored on a file or paper which can be stolen at any time.

An online wallet has too much security for this. Like Two-Step Verification, or a pin code, etc..