In today’s scenario, the Internet of Things (IoT) has transformed people’s lives by enabling data exchange among pervasive devices in various applications. However, clock synchronization is essential to ensure seamless transmission and synchronization among IoT entities involved in processing and communication. This paper proposes a clock synchronization algorithm based on linear-quadratic regression (LQR) to address synchronization-errors in IoT applications. The algorithm uses a linear model of skew and offsets to estimate clock parameters, and performance is evaluated in terms of R-square error (RSE) and Root Mean Square Error (RMSE). Our proposed algorithm outperformed traditional algorithms with an R-Square Error of 0.71% and RMSE of 0.379%. This paper also evaluated the stability of the proposed model using the correlation coefficient, which indicated a high correlation among the variables at 86%. The results below demonstrate the proposed algorithm’s effectiveness and goodness of fit in addressing clock synchronization errors for IoT applications.