This dataset contains annual time series data on cocoa producer prices, area harvested, inflation rates, rainfall, and international cocoa prices for Nigeria and Ghana from 1980 to 2023. It was compiled to support the empirical analysis of price bubbles in cocoa markets and their effects on agricultural investment decisions. The variables were sourced from national and international databases, including the FAO, World Bank, and national statistical agencies. Each variable was selected to reflect core aspects of agricultural market behaviour, price dynamics, and investment responses, particularly in the context of perennial crops like cocoa. The data serves as the basis for ARDL and bubble detection tests (SADF/GSADF) used in this study.