Can iOS 11.0.3 automatically logout from WhatsApp? My phone storage was full and I couldn't open WhatsApp. I put the phone on charging and the next day when I tried to open WhatsApp, I was logged out. I had to provide my phone no and other information to login as we do when we change our device. Also, all of my WhatsApp data was gone, messages, history and pictures. Although, the saved media was still available via the Photos app. Was my WhatsApp account hacked, or did iOS deleted the data? 

Also offload unused apps setting (available under Settings app -&gt; General -&gt; iPhone Storage)was not enabled. I am using an iPhone 5S 16GB.
No, iOS can't delete your WhatsApp account.  iOS can't, on its own, delete any account for any app.

You stated you didn't have Offload Unused App enabled so it's more probable that WhatsApp didn't have the available space it needed to store your history.

iOS will determine if it needs to 'unload' an app from memory to make space for system process, another app's use, etc.  I can't say for sure but it appears that WhatsApp was removed from memory because the system needed to reclaim that memory to use for something else.

If you delete apps you don't need, turn on Offload Unused Apps, and then reinstall WhatsApp, you might see your history return.  This answer from a similar question might help, too.  That user stopped all apps using the app switcher and then restarted their iPhone.  That helped them regain space and add their apps back.