WhatsApp does not have a logout mechanism. The application is designed to always be connected so that you receive your messages quickly, even when you are not actively using your phone. This is similar to how SMS works and allows WhatsApp messages to be delivered almost instantly.
We understand that this may raise concerns about battery life and data usage, but rest assured that we take these issues very seriously and strive to conserve battery and data as much as possible. We continue to make improvements in every version.
WhatsApp strongly recommends that you have an unlimited data plan. WhatsApp works by using your Internet data plan to send and receive messages (just like emailing). So, if you do not have an unlimited data plan, WhatsApp may consume your data allowance and your mobile service provider may charge you accordingly.
It is possible to prevent WhatsApp from using your data network while you are roaming. To learn how to turn off cellular data when roaming read this article.