To Count unique values in a column in pandas dataframe You can Also Use pd.DataFrame.agg just like this. We are using the same example as I mentioned in method 1. Just put ['count', 'size', 'nunique'] into pd.DataFrame.agg and it will return you total_count of the column, total_size of columns, and total_unique value count. Hope You understand. Thanks.