The decision to leave the European Union will result in strong economic headwinds across the U.K., dragging down its growth over the next two years, S&P Global Ratings said in a report released Monday. Reeling under the impact of Brexit, the country will "barely escape a full-fledged recession," the credit rating agency warned.

"Overall, our current estimates suggest that Brexit will produce a drag amounting to 1.2 percent of GDP for the U.K. in 2017 and 1 percent in 2018. These new estimates assume that access to the single market is maintained in 2017 and 2018, and that the BoE succeeds in keeping turmoil in financial markets in check," S&P said in its report.

The agency also forecast that the Bank of England, which recently hinted at a further rate cut later this summer, would slash its key interest rate to zero from the current level of 0.5 percent, despite the pickup in inflation caused by a weak pound.

The U.K.'s economic outlook has been clouded by the surprise vote to exit the EU. Since the June 23 referendum, the pound has fallen over 11 percent against the dollar, hitting levels not seen in over three decades. Last week, the British Chancellor of the Exchequer George Osborne was forced to abandon a key economic goal outlined earlier this year — to return the government's finances to a surplus by 2020.

According to the S&P, the economic impact of Brexit is likely to be felt through three major channels of transmission — the pound sterling exchange rate, trade and investor confidence. While the weak pound is likely to boost exports over the next two years, the benefits may be offset by the concomitant rise in domestic inflation.

"Heightened uncertainties about the future of the U.K. and its relations with the EU will no doubt hurt consumer sentiment. The household savings rate had been steadily declining since 2013, underpinning robust growth in consumption," S&P said in the report. "As inflation spikes, the lower growth in real income and a more uncertain environment are likely to curb consumer demand in the next couple of years. And a key risk is whether that weaker demand will hit the residential real estate market."

Moreover, the ripples of the U.K. exiting the 28-nation EU are likely to be felt across the eurozone. According to S&P's analysis, the eurozone is likely to suffer a 0.8 percentage point hit to the GDP in 2017 and 2018 as a result of Brexit.