Internet of Things (IoT)-based Wireless Body Area Networks (WBANs) play an important role in modern medical systems for patient-health monitoring. WBANs have the capability to collect real-time biological information from the patients’ body through some intelligent sensors and then send the collected information to the remote doctors or medical experts through Internet. In the recent years, numerous anonymous authentication schemes were proposed to provide security in wireless body area networks. However, many of these schemes are not computationally efficient during anonymous authentication. Moreover, the previous schemes did not provide location privacy for both the doctors and patients. In order to overcome these limitations, in this project, we propose an efficient and secure anonymous authentication framework with location privacy preservation for IoT-based WBANs. The comprehensive analysis section shows that the proposed scheme overcomes the security weaknesses in the existing schemes and also provides low computation cost during anonymous authentication.