Government intervention is imperative in the mixed economic system due to market failures, imperfection, pure public goods, and economic externalities. To this end, we measure the comparative impact of budget deficits on economic growth, incorporating the moderating role of quality of governance (QOG) for welfare and non-welfare countries. We apply a newly developed econometric model, namely Panel Quantile Regression via Moment Conditions, considering the scale and location effect due to high heterogeneity in our panel time series data over 1990–2020. Our empirical investigation shows that the budget deficit promotes economic growth sustainability in the overall sample countries. The comparative analysis confirms that budget deficit promotes economic growth for welfare countries while it impends for non-welfare countries. Furthermore, QOG augments sustainable economic growth in different economic circumstances in welfare countries and non-welfare countries. Finally, the results also demonstrate that the QOG plays a supportive role in the nexus between budget deficit and economic growth in the full sample countries. The findings indicate that the effectiveness of the budget deficit varies across welfare and non-welfare countries. In general, QOG promotes economic growth, but its stringent rules and restrictions somewhat slow down the wheel of the growth process. We provide several policy implications.