The existence of undetected direct path (UDP) conditions causes occurrence of unexpected large random ranging errors which pose a serious challenge to precise indoor localization using time of arrival (ToA). Therefore, analysis of the behavior of the ranging error is essential for the design of precise ToA-based indoor localization systems. In this paper, we propose a novel analytical framework for the analysis of the dynamic spatial variations of ranging error observed by a mobile user based on an application of Markov chain. The model relegates the behavior of ranging error into four main categories associated with four states of the Markov process. The parameters of distributions of ranging error in each Markov state are extracted from empirical data collected from a measurement calibrated ray tracing (RT) algorithm simulating a typical office environment. The analytical derivation of parameters of the Markov model employs the existing path loss models for the first detected path and total multipath received power in the same office environment. Results of simulated errors from the Markov model and actual errors from empirical data show close agreement.