These recent years have witnessed the importance of indoor localization and tracking as people are spending more time indoors, which facilitates determining the location of an object. Indoor localization enables accurate and reliable location-based services and navigation within buildings, where GPS signals are often weak or unavailable. With the rapid progress of smartphones and their growing usage, smartphone-based positioning systems are applied in multiple applications. The smartphone is embedded with an inertial measurement unit (IMU) that consists of various sensors to determine the walking pattern of the user and form a pedestrian dead reckoning (PDR) algorithm for indoor navigation. As such, this study reviewed the literature on indoor localization based on smartphones. Articles published from 2015 to 2022 were retrieved from four databases: Science Direct, Web of Science (WOS), IEEE Xplore, and Scopus. In total, 109 articles were reviewed from the 4186 identified based on inclusion and exclusion criteria. This study unveiled the technology and methods utilized to develop indoor localization systems. Analyses on sample size, walking patterns, phone poses, and sensor types reported in previous studies are disclosed in this study. Next, academic challenges, motivations, and recommendations for future research endeavors are discussed. Essentially, this systematic literature review (SLR) highlights the present research overview. The gaps identified from the SLR may assist future researchers in planning their research work to bridge those gaps.