pd.DataFrame( {'a':['A','A','B','B','B','C'], 'b':[1,2,5,5,4,6]}) df.groupby('a')['b'].apply(list) Out: a A [1, 2] B [5, 5, 4] C [6] Name: b, dtype: object