The underlying data source for web usage mining (WUM) is commonly thought to be server logs. However, access log files ensure quite limited data about the clients. Identifying sessions from this messy data takes considerable effort, and operations performed for this purpose do not always yield excellent results. Also, this data cannot be used for web analytics efficiently. This study proposes a method for user tracking, session management, and collecting web usage data. The method is mainly based on an innovative approach for using collected data for web analytics extraction as the data source in web usage mining. An application-based API has been developed with a different strategy from conventional client-side methods to obtain and process log data. The log data has been successfully gathered by integrating the technique into an enterprise web application. The results reveal that the homogeneous data collected and stored with this method is more convenient to browse, filter, and process than web server logs. This structured data can be used effortlessly as a reliable data source for high-performance web usage mining activity, real-time web analytics, machine learning algorithms, or a functional recommendation system.