Short-term prediction of passenger flow plays an important role in realtime bus dispatching. Such prediction is also useful in diagnosing bus operation problems, such as forecasting bus bunching. A novel framework is proposed in this paper to predict the passenger flow at bus stops. The framework consists of three sequential stages. In the first stage, a seasonal ARIMA-based method is used to predict the arrival passenger count and empty space on a bus when the bus reaches a bus stop. The historical passenger arrivals at the bus stop can he obtained from the corresponding hoarding count data by an allocation approach. In the second stage, an event-based method is developed to predict the departure passenger counts from the stop. The proposed method iteratively forecasts the bus arrival events and consequently updates the passenger flow. In the third stage, a Kalman filter-based method is proposed to predict the waiting passenger counts at the stop according to results from the first and second stages. The rcal-time observed waiting passenger count is used as the feedback of the filter to minimize the prediction error. Computational results based on the real bus line data for passenger flow prediction and its application in forecasting bunching confirm that the proposed framework and solution algorithm are effective in providing accurate and reliable passenger flow prediction.