By default, if your device is connected to the internet, you are shown to your contacts as Online in the WhatsApp. To hide last seen status and become invisible in WhatsApp for Android, do as follows:
1. Open WhatsApp on your Android device
2. Tap the 3dot icon the top right and go to the Settings.
3. Follow this path: Account >> Privacy
4. Under the Who Can See Personal Info, touch the Last Seen option
5. You can specify who should see your online status: Everyone, Contacts, Nobody