Big data analytics have shown a tremendous impact on modern politics—among which the election forecasting modeling is notable that utilizes the large scale heterogeneous data sources, such as polls, surveys, and social media popularity to build prediction models by exploiting the power of machine learning and artificial intelligence. In this article, we present a novel machine learning-based election forecasting model that predicted Pakistan’s 2018 General Election with the highest accuracy and won a nation-wide competition. To capture the winning probability of individual candidates in a constituency, the model taped an array of statistics from different data sources. Past election data was employed to mine demographic trends of each party across the districts, Twitter, and approval polls were exploited to snap current popularity levels. By employing Bayesian optimization, the model combined the probabilities from different sources by ‘rigging’ the results for ten seats as a win, where competition was expected to be one-sided. In contrast to the existing models that only predict the aggregate share of votes for different political parties at the national level, our model also effectively predicted the winning candidates for every national assembly seat. The seat share of political parties in the national assembly was predicted with 83% accuracy. Of the total 270 constituencies, 230 winners were among the top two candidates, predicted by the proposed technique. Our model produces the most accurate results of the election compared to all the opinion polls and surveys held before the election 2018 in the country. We showed that big data tools and techniques coupled with the right mixture of machine learning and artificial intelligence models could have a significant impact on modern day political landscape.