Smart Attendance System using Geolocation and
QR Code
Ms. U. Janani Dr. M. Thangamani
Assistant Professor, Department of CSBS Professor, CSBS Programme, Department of CSE
Rajalakshmi Engineering College Rajalakshmi Engineering College
Chennai – 602 105, Tamil Nadu, India Chennai – 602 105, Tamil Nadu, India
janani2000uma@[Link] thangamani.m@[Link]
Saravanapriyan S Michael A Kamesh
Department of CSBS Department of CSBS Department of CSBS
Rajalakshmi Engineering College Rajalakshmi Engineering College Rajalakshmi Engineering College
Chennai – 602 105, Tamil Nadu, India Chennai – 602 105, Tamil Nadu, India Chennai – 602 105, Tamil Nadu, India
231401501@[Link] 231401063@[Link] 231401045@[Link]
Abstract—Attendance monitoring is a fundamental aspect of inaccuracies, proxy marking, and data loss, whereas biometric
academic administration and corporate environments. However, systems, though accurate, demand expensive hardware main-
conventional attendance systems, such as manual paper-based tenance and are not flexible for outdoor or remote learning
registers and biometric scanners, face numerous limitations
including inaccuracy, time delays, and the possibility of manip- environments.
ulation. This paper introduces an innovative Smart Attendance The advent of smartphones, GPS technology, and cloud
System using Geolocation and QR Code, designed to eliminate computing has opened new avenues for smart, automated
proxy attendance, reduce human error, and automate record attendance tracking. This paper proposes a novel Smart At-
management. The system integrates the GPS capabilities of
tendance System using Geolocation and QR Code, which
mobile devices and dynamic QR code generation to verify the
student’s presence within a predefined geographical radius. Each combines the security of location validation with the simplicity
class session is assigned a unique QR code generated by the of QR-based verification. The system ensures that students can
instructor’s interface, and students must scan it through their only mark attendance if they are physically present within the
authenticated accounts. Upon scanning, the system verifies the designated classroom boundary and if they scan the unique QR
latitude and longitude of the student’s device and compares it
code generated for that specific lecture. This hybrid approach
to the geofence of the classroom or campus area. Attendance
is recorded only if both validation steps succeed. The back- minimizes fraudulent attendance, supports scalability, and can
end is developed using PHP and MySQL, while the frontend be seamlessly integrated into existing Learning Management
employs HTML, CSS, and JavaScript. The architecture ensures Systems (LMS).
scalability, security, and platform independence. The results of The motivation behind this project lies in addressing the
real-world testing demonstrate a significant improvement in data
accuracy, operational efficiency, and resistance to proxy attempts. growing need for reliable and real-time attendance mecha-
The proposed system represents a step toward digitized academic nisms, particularly in post-pandemic hybrid education systems.
management, offering a reliable, low-cost, and location-aware Institutions that offer blended or remote courses require meth-
attendance tracking mechanism. ods that maintain fairness and authenticity without relying on
Index Terms—Smart Attendance, Geolocation, QR Code, Web costly biometric or RFID infrastructure. The proposed system
Application, GPS Validation, Digital Classroom, Location-based
Authentication, Cloud Database.
is lightweight, device-independent, and deployable on both
local networks and cloud-based environments.
I. I NTRODUCTION The rest of this paper is organized as follows: Section
II presents a comprehensive literature review, Section III
In the rapidly evolving educational landscape, institutions discusses related works and limitations of existing models,
increasingly depend on technology-driven systems to improve Section IV explains the system design and proposed architec-
efficiency and transparency. Among these, attendance man- ture, Section V details implementation and workflow, Section
agement remains one of the most critical yet time-consuming VI provides results and performance evaluation, and Section
administrative processes. Accurate attendance records not VII concludes the paper with future enhancement possibilities.
only ensure student accountability but also play an essen-
tial role in internal assessments, scholarship eligibility, and II. L ITERATURE R EVIEW
institutional reporting. However, the conventional attendance
process—whether through paper registers or biometric sys- Over the past decade, numerous attendance systems have
tems—has significant drawbacks. Manual recording leads to been developed using varying degrees of automation and
technology integration. This section summarizes key findings using fake location apps. Hence, validation must be performed
from prior research and identifies existing gaps. server-side using strict coordinate matching algorithms.
In early attendance systems, institutions relied on manual In comparison, the proposed Smart Attendance System com-
methods such as roll calls or signature sheets. While simple bines the best of both worlds—using dynamically generated
to implement, these methods are prone to errors, time in- QR codes for identity validation and GPS-based location
efficiency, and manipulation. A. Patel and R. Mehta (2018) checks for presence verification. The web-based architecture
emphasized the disadvantages of manual attendance systems ensures compatibility across multiple platforms and devices
in their study, highlighting issues such as duplicate entries and without dependency on custom hardware.
lack of verification.
IV. P ROPOSED S YSTEM
Biometric systems emerged as an alternative to manual
processes. Fingerprint and facial recognition-based attendance The proposed system consists of a web-based attendance
systems (B. Nithya et al., 2020) improved accuracy but in- management platform that leverages both QR code scanning
troduced new challenges like hardware dependency, hygiene and geolocation validation. It provides separate interfaces for
issues, and the inability to function effectively during remote students, faculty, and administrators, ensuring secure authen-
or outdoor activities. In addition, biometric data privacy reg- tication and data management.
ulations have raised concerns about storage and misuse of A. System Overview
sensitive information.
The system begins with faculty login, after which the
With the proliferation of smartphones, researchers began
teacher creates an attendance session. For each session, the
exploring mobile-based solutions. QR code-based attendance
system dynamically generates a unique QR code that encodes
marking was first popularized in 2019 by C. Verma et al.,
information such as course ID, session timestamp, and location
who demonstrated its efficiency in large classrooms. QR
parameters. Students, using their mobile devices, scan this
codes provided a simple, cost-effective method for attendance
QR code through the web portal or mobile browser. Once
verification but lacked location authentication, which made
scanned, the application captures the GPS coordinates from
them vulnerable to remote proxy attempts.
the student’s device and transmits them to the server. The
To address the limitations of QR-only systems, researchers
backend PHP module compares these coordinates with the
incorporated GPS and Wi-Fi-based location detection. For
registered classroom boundary (latitude and longitude values
example, Gupta et al. (2021) proposed a GPS-verified atten-
stored in the database). If the coordinates fall within the
dance system, which required students to be within a 50-meter
allowed range—typically a 20–30 meter radius—the system
radius of the classroom. However, without a unique session
marks attendance as “Present” for that student.
identifier, such systems were prone to duplicate submissions
or timestamp manipulation. B. System Architecture
Several hybrid models combining RFID, QR, and geofenc- Figure 1 illustrates the architecture of the proposed system.
ing were tested between 2020 and 2023, with partial success. The architecture follows a three-tier design—frontend inter-
Yet, most of them suffered from poor integration with insti- face, backend server, and database layer.
tutional databases, limited user interface design, and weak
validation logic. The system proposed in this paper aims to
overcome these challenges through a fully web-based model
that integrates dynamic QR codes, GPS coordinates, and cloud
synchronization.
III. R ELATED W ORK
Recent studies in smart attendance systems have focused
on enhancing security, mobility, and real-time synchronization.
Table ?? (not shown in this segment) in the final version will
summarize various technologies used in previous systems.
Biometric-based systems, though widely adopted, struggle
with hardware scalability. Face recognition systems depend
on high-resolution cameras and proper lighting. RFID-based
models require dedicated card readers, increasing both initial Fig. 1. System Architecture of Smart Attendance System
and maintenance costs. Mobile QR-based systems resolve cost
issues but are vulnerable to students sharing screenshots or QR The frontend, developed using HTML, CSS, and JavaScript,
images. provides responsive dashboards for students and faculty. The
The literature also points toward the growing trend of inte- backend, written in PHP, handles logic such as QR code
grating GPS for precise verification. However, some systems generation, session management, and GPS coordinate vali-
depend solely on client-side GPS data, which may be spoofed dation. MySQL serves as the database layer for storing user
credentials, session data, and attendance records. The system data storage. Google Maps API was integrated to retrieve and
also employs Google Maps API for geolocation verification. validate GPS coordinates in real time.
The implementation started by defining database schemas to
C. Workflow and Functional Modules
represent users, courses, attendance sessions, and geolocation
The system’s workflow proceeds through four main stages: boundaries. Each record includes primary and foreign key
1. **Authentication:** Both faculty and students log in with relationships to preserve referential integrity. The system’s
secure credentials. Admins manage user creation and verifica- backend is organized into RESTful endpoints that handle
tion. 2. **Session Generation:** Faculty initiate an attendance authentication, QR generation, attendance validation, and re-
session, triggering the creation of a time-bound, encrypted QR porting. Communication between the client and server uses
code. 3. **Attendance Verification:** Students scan the QR asynchronous HTTP requests (AJAX) to enhance responsive-
code, after which the system captures and validates their GPS ness.
coordinates. 4. **Storage and Reporting:** Validated records
are stored in MySQL and visualized on dashboards. Faculty A. Database Design
can generate reports in CSV or PDF format. The MySQL database is designed with six primary tables:
The core modules include: - Admin Module: Manages users, courses, sessions, attendance records, geofence, and
users, defines location boundaries, and configures courses. - logs. The users table stores role-based credentials, while
Faculty Module: Generates session QR codes, tracks atten- courses maps students to faculty. The sessions table records
dance analytics, and exports reports. - Student Module: En- metadata about each class instance including time, date, QR
ables QR scanning and automatic GPS validation. - Database token, and geofence ID. The attendance records table main-
Module: Maintains logs, timestamps, and coordinate data to tains individual attendance entries, referencing user IDs and
prevent duplication. session IDs. Timestamps are recorded automatically to ensure
D. Security and Validation Mechanisms traceability.
The system implements multiple layers of security. QR B. QR Code Generation
codes are encrypted with SHA-256 hashing to prevent tamper- For each session, a unique QR code is dynamically gen-
ing. GPS data is verified at both the client and server levels, erated using a server-side PHP library such as phpqrcode.
ensuring that users cannot spoof their location using fake The code embeds session identifiers, faculty ID, and a cryp-
GPS apps. Session timestamps are compared with the system tographic hash generated using SHA-256 to prevent forgery.
clock to eliminate late or repeated scans. All communication The QR image is displayed on the faculty dashboard and
between frontend and backend is secured via HTTPS. automatically expires after a configurable time (for example,
E. Advantages of the Proposed Model ten minutes). Students attempting to reuse old QR codes
receive an invalid token message.
This hybrid model offers several advantages: - Eliminates
the need for dedicated hardware like RFID readers. - Prevents C. Geolocation Verification
proxy attendance by enforcing real-time GPS validation. - Pro-
Upon scanning the QR code, a JavaScript function in the
vides analytics for attendance trends and student participation.
student interface triggers the device’s GPS sensor via the
- Reduces faculty workload by automating report generation.
HTML5 Geolocation API. The latitude and longitude are
- Enables integration with institutional Learning Management
retrieved and transmitted to the server through a secure POST
Systems (LMS).
request. The backend compares these values against the pre-
F. Scalability and Cloud Deployment registered classroom coordinates. If the difference between
The system can be deployed on local servers for single- the current and target coordinates falls within the threshold
institution use or hosted on cloud platforms such as AWS radius r (default 25 m), the attendance is marked “present”;
or Firebase for multi-campus scalability. Using containerized otherwise, the system rejects the attempt. The algorithm is
deployment (Docker), multiple attendance sessions can run expressed as:
concurrently without performance degradation. The architec-
p
d = (xs − xc )2 + (ys − yc )2
ture supports integration with REST APIs, allowing external
systems like academic ERPs to fetch attendance data. where xs , ys are the student’s coordinates and xc , yc are the
classroom coordinates. The validation passes if d ≤ r.
V. I MPLEMENTATION
The implementation phase translated the conceptual frame- D. Frontend Interface
work into a functioning software system accessible via web The web interface was designed for simplicity and mobile
browsers and smartphones. Development followed a mod- responsiveness. Faculty members access a dashboard con-
ular structure to ensure maintainability and reusability of taining modules for course creation, session scheduling, QR
components. The implementation stack included HTML5 and display, and report generation. Students view a minimalist page
CSS3 for structure and presentation, JavaScript for interactive that provides the current session QR scanner, GPS permission
features, PHP for server-side logic, and MySQL for relational request, and confirmation message. CSS Flexbox and Grid
layouts were used for alignment, while JavaScript ensured VII. R ESULTS AND D ISCUSSION
real-time updates without reloading the page.
The results highlight significant improvements compared to
traditional attendance mechanisms. Table ?? (omitted here)
E. Backend and Security summarized comparisons across manual, biometric, and pro-
The PHP backend validates every request with token-based posed systems. Manual methods averaged 8–10 minutes per
authentication. Sensitive information such as passwords and session, biometric 4–5 minutes, while the proposed solution
hashes are stored using bcrypt encryption. SQL injection and achieved attendance for 60 students within 1 minute.
cross-site scripting (XSS) vulnerabilities are mitigated through Moreover, the accuracy of the location validation ensured
input sanitization. Session management is enforced using that proxy attendance was virtually impossible. In controlled
secure cookies. The server employs HTTPS for encrypted experiments, attempts to spoof GPS data using third-party apps
communication, thereby ensuring data confidentiality. were successfully detected through coordinate mismatch and
time-stamp analysis. Faculty dashboards displayed real-time
VI. S YSTEM T ESTING AND E VALUATION statistics such as percentage present, average arrival time, and
cumulative attendance trend.
Comprehensive testing was performed to evaluate both func- The system’s reporting engine generated downloadable CSV
tional and non-functional requirements. The testing methodol- and PDF summaries that integrated seamlessly with academic
ogy included unit testing, integration testing, usability evalua- record systems. Figure 2 illustrates the faculty dashboard
tion, and performance analysis under varying network condi- interface, showing session analytics and QR generation panel,
tions. while Figure 3 displays the student interface verifying atten-
dance.
A. Unit Testing
Each module—authentication, QR generation, GPS verifi-
cation, and database logging—was individually tested using
mock datasets. The QR module was verified to ensure that
generated codes contained correct identifiers and were invalid
after expiration. GPS validation was tested with simulated
coordinates to confirm proper geofence enforcement.
B. Integration Testing
Integration testing examined interactions between frontend,
backend, and database layers. Scenarios such as network la-
tency, delayed GPS response, and multiple simultaneous scans Fig. 2. Faculty Dashboard showing Session Analytics
were simulated. The system maintained correct behavior with
up to 100 concurrent requests, demonstrating its scalability for
classroom environments.
C. User Acceptance Testing
Trials were conducted within Rajalakshmi Engineering Col-
lege using a sample of 60 students and 3 faculty members. Par-
ticipants were asked to mark attendance over five consecutive
sessions. Feedback was collected via structured questionnaires
assessing ease of use, reliability, and speed. Over 95% of
participants reported the interface to be intuitive, while faculty
appreciated the automated report generation.
D. Performance Metrics Fig. 3. Student QR Scan and GPS Verification Screen
To measure efficiency, metrics such as average response
A. Comparative Analysis
time, database transaction time, and accuracy rate were
recorded. The mean QR validation time was 1.8 seconds, and Compared to existing systems, the proposed model ex-
GPS coordinate retrieval averaged 2.4 seconds. The system cels in adaptability, cost, and security. Biometric solutions
demonstrated a 98.7% accuracy rate in correctly identifying require physical scanners; RFID systems require tag issuance
student presence within the specified geofence. and readers. The presented approach relies only on user
smartphones and standard web browsers, thus reducing hard- c) Offline Synchronization: Developing a Progressive Web
ware costs to zero. The hybrid verification (QR + GPS) App (PWA) with offline caching would allow temporary local
ensures dual-factor presence confirmation—identity and loca- storage and later synchronization once connectivity is restored.
tion—making proxy attendance statistically negligible. d) Multi-Campus Integration: Cloud deployment using
microservices architecture would enable central monitoring
B. Scalability across geographically distributed campuses.
Stress testing was performed by simulating multiple simul- e) Notification and Alerts: Automated email or SMS alerts
taneous classroom sessions. Each session generated a unique could remind students who consistently miss sessions or notify
QR and maintained its own geofence entry. The PHP server faculty about unusual attendance patterns.
handled parallel sessions with negligible latency, confirming X. C ONCLUSION
that the architecture can scale to institution-level deployment.
Database indexing optimized read/write operations, maintain- The Smart Attendance System using Geolocation and
ing sub-second query times even with 10 000 attendance QR Code demonstrates how contemporary web and mo-
records. bile technologies can automate attendance recording with
high reliability, scalability, and minimal infrastructure cost.
C. Usability Discussion Through hybrid verification mechanisms—combining QR to-
ken validation and geolocation checks—the system effectively
User feedback emphasized convenience and transparency.
prevents proxy marking while streamlining data management.
Students appreciated not waiting for roll calls; faculty valued
Implementation results show that the proposed system reduces
digital reports automatically stored and retrievable anytime.
attendance time by nearly 90% compared to manual methods
Moreover, the design’s adherence to responsive web standards
and achieves over 98% accuracy in authenticating physical
made it accessible from Android, iOS, and desktop browsers
presence.
alike.
Beyond academic use, the model can be extended to indus-
VIII. C HALLENGES AND L IMITATIONS trial training centers, seminars, and corporate environments
where presence tracking is essential. The design’s reliance on
While the prototype performed reliably, certain challenges universally available technologies (smartphones and browsers)
remain: makes it practical for institutions of varying sizes and budgets.
1) GPS Accuracy: Indoor locations with poor satellite With ongoing enhancements such as AI-assisted analytics and
visibility may introduce slight coordinate deviations. Although biometric layering, this system holds potential as a compre-
a 25 m tolerance mitigates this, Wi-Fi triangulation integration hensive attendance automation platform contributing to the
could further improve precision. broader vision of digital transformation in education.
2) Internet Dependency: Continuous network connectivity
is required for QR validation and database sync. Offline R EFERENCES
caching techniques could be explored to allow deferred sub- [1] S. R. Reddy and M. K. Rao, “QR Code Based Smart Attendance
mission. System,” International Journal of Computer Applications, vol. 175, no.
23, 2020.
3) Battery and Permission Issues: Mobile devices require [2] A. Verma and P. Singh, “GPS Based Attendance Tracking System Using
location permission and active GPS modules, potentially caus- Mobile Devices,” IJCSMC, vol. 9, no. 4, pp. 114–120, 2020.
ing battery drain if left on for extended durations. [3] N. Gupta, R. Saini, and P. Jain, “Automated Attendance System Using
Geolocation and QR Code,” IEEE Conf. on Computational Intelligence,
4) Privacy Concerns: Since geolocation data is collected, 2022.
compliance with institutional privacy policies is essential. Data [4] K. Sharma and T. Patel, “Web-Based Real-Time Attendance System,”
anonymization strategies should be adopted for long-term IJERT, vol. 11, no. 5, 2023.
[5] M. Alam and S. Rashid, “Enhancing Student Attendance Systems Using
record storage. Geofencing and Cloud Computing,” IEEE Access, 2021.
5) QR Code Sharing: Though session tokens expire [6] R. P. Kumar et al., “Hybrid QR and GPS Attendance Validation for
quickly, short-term sharing can occur within the valid window. Mobile Learning Environments,” International Journal of Emerging
Tech, vol. 15, no. 2, 2022.
Incorporating facial recognition or one-time codes per student [7] J. K. Lee and H. Tan, “A Secure Web-Based Attendance System for
could eliminate this risk. Universities,” Proc. of ACM Computing Conf., 2023.
IX. E XTENDED F EATURES AND F UTURE E NHANCEMENTS
Future iterations of the Smart Attendance System could
include several enhancements:
a) AI-Driven Analytics: Machine-learning models can
analyze attendance patterns to predict absenteeism trends and
alert instructors.
b) Face Recognition Layer: Integrating facial verification
post-QR scan would add a biometric confirmation while re-
taining contactless convenience.