1. A method comprising: receiving, by a mobile device and from a storage device coupled to the mobile device, a state model, the state model comprising a plurality of states and transitions between the states, each state corresponding to a location, each transition from a first state to a second state indicating that the mobile device moved from a corresponding first location to a corresponding second location, each state and each transition being associated with a one or more timestamps; receiving, by the mobile device, a request for predicting a future location of the mobile device, the request specifying a future time; determining, using a current time, the future time, and a current location of the mobile device as inputs, and based on the states, transitions and associated timestamps in the state model, a probability for associating with each state, the probability indicating a likelihood that the mobile device will be located at the location corresponding to the state at the future time; and based on the probabilities, providing a location associated with at least one state as a predicted future location in response to the request.