Egypt's agricultural sector plays a critical role in the country's economy, with wheat cultivation being vital for ensuring food security. However, the challenges faced by wheat farming in Egypt, such as climate change, water scarcity, and pest infestations, contribute to yield fluctuations, highlighting the need for accurate and timely predictions of wheat productivity. To address this need, time series analysis is employed, which involves analyzing data collected at regular intervals over a specific time frame. Time series data can encompass multiple variables recorded simultaneously at each interval, known as multivariate time series data. Traditional statistical methods have been commonly used for time series analysis. However, these methods have limitations when dealing with nonlinear and complex data patterns, especially in agricultural data exhibiting spatiotemporal characteristics. Deep learning techniques have emerged as a promising solution to address these limitations. In this paper, we have developed the Multivariate Multi-Head Attention Temporal Convolutional Networks (MATCN) model specifically to handle the spatiotemporal nature of multivariate time series data in the context of wheat crop productivity prediction in Egypt. The experimental results revealed that our proposed MATCN model exhibited the most effective prediction performance when compared to other state-of-the-art models.