About half of the total health-related economic cost due to outdoor air pollution can be attributed to the road transport sector. As a result, some countries, like Norway, are considering plans to ban petrol and diesel powered vehicles by 2025. State of charge (SOC) estimation is critical to the safe and reliable operation of Li-ion battery packs, which nowadays are becoming increasingly used in electric vehicles (EVs), Hybrid EVs, unmanned aerial vehicles, and smart grid systems. We introduce a new method to perform accurate SOC estimation for Li-ion batteries using a recurrent neural network (RNN) with long short-term memory (LSTM). The time series-nature of battery data is a great fit for a LSTM-RNN which is widely recognized for its strong performance when encoding dynamics in time. We showcase the LSTM-RNN’s ability to encode dependencies in time and accurately estimate SOC. The LSTM-RNN can map battery measurement signals like voltage, current, and temperature directly to the battery SOC, avoiding computationally intensive filters and inference algorithms like Kalman filters used in traditional SOC estimators. In addition, this machine-learning technique, like all others, is capable of generalizing the abstractions it learns during training to other datasets taken under different conditions. Therefore, we exploit this feature by training an LSTM-RNN model over datasets recorded at various ambient temperatures, leading to a single network that can properly estimate SOC at different ambient temperature conditions. This is beneficial since incumbent estimation techniques must use different models or different lookup tables for different ambient temperatures. The LSTM-RNN achieves a low mean absolute error (MAE) of 0.573% at a fixed ambient temperature and an MAE of 1.606% on a dataset with ambient temperature increasing from 10 to 25 ◦C.