Two-factor authentication (2FA) is a widely adopted security measure that requires users to provide an additional layer of authentication beyond a username and password in order to access protected resources. While traditional 2FA methods rely on the user to manually enter a code or token, the use of machine learning (ML) has the potential to revolutionize 2FA by enabling automatic and continuous verification of a user’s identity. In this paper, we propose a continuous zero effort 2FA system that uses ML to verify a user’s identity based on the unique characteristics of their environment, including beacon frame characteristics and RSSI values collected from Wi-Fi access points (APs). This system allows for seamless and automatic authentication without requiring any additional input or action from the user beyond their initial login. Additionally, the continuous authentication feature of the proposed system ensures that access to protected resources is maintained only when the user’s two devices are co-located. Through experiments, we demonstrate the effectiveness of the proposed system in determining the location of the user’s devices based on beacon frame characteristics and Received Signal Strength Indicator (RSSI) values. The proposed system offers a convenient and secure solution for 2FA that utilizes the power of ML to enable automatic and continuous authentication. Furthermore, its scalability, flexibility, and adjustability make it a promising option for organizations and users who need a secure and convenient authentication system. Finally, we have included three Python codes in the appendix, which provide further insights into our evaluation and analysis of the proposed system.