The sequences of users' behaviors generally indicate their preferences, which can be used to improve next item prediction in sequential recommendation. Unfortunately, the users' behaviors may change over time, and it remains a great challenge to capture the user's dynamic preference directly from her/his recent behaviors sequence. Traditional methods such as Markov Chains, Recurrent Neural Networks, and Long Short-Term Memory (LSTM) Networks only consider the relative order of items in sequence, but ignore some important time information, such as the time interval and duration in the sequence. In this paper, we propose a novel sequential recommendation model, named Interval and Duration aware LSTM (IDLSTM), which leverages the interval and duration information to accurately model users' long-term and short-term preferences. In particular, the IDLSTM model incorporates the global context information of the sequence in the input layer to make better use of long-term memory. Furthermore, we also present an improved version of IDLSTM, namely IDLSTM with Embedding layer and Coupling input and output gates (IDLSTM-EC), which introduces the coupled input and forget