Bydefault in WhatsApp chats are automatically backed up and saved daily to your phone's memory. If you are uninstalling WhatsApp from the phone and don't want to lose your messages, be sure to manually back up your chats before uninstalling.
Whatsapp Back up chats
Go to WhatsApp > Settings > Chats > Chat backup > BACK UP.
If you want to export chat history please follow the below steps.You can use the export chat feature to export a copy of the chat history from an individual or group chat.
In Whatsapp open the individual or group chat.
Click on three dots > More > Export chat.
Then it will ask to export with media or without media.
Selet option with media or without Media then an email will be composed with your chat history attached as a .txt document.
You can also check in the video link
https://www.youtube.com/watch?v=L1yVpT4WSKk