Global oil markets could witness a modest surplus into early 2019 as new spare capacity comes online, despite strong demand and uncertainty on the size of supply losses from Iran due to U.S. sanctions set to start next month, Goldman Sachs said.

"While upside price risks will prevail for now, fundamental data outside of Iran has not turned bullish in our view," the bank said in a note dated Thursday.

"We expect fundamentals to gradually become binding by early 2019 as new spare capacity comes online."

Goldman said there was a higher initial inventory buffer heading into the fourth quarter due to a production surge in Saudi Arabia in June, and output in volatile regions like Libya and Nigeria was 0.3 million barrels per day above expectations.

Recent political shifts in Iraq increased the likelihood of a ramp-up in Kurdistan production, it added.

Oil prices rose on Friday, as traders focused on U.S. sanctions against Iran's crude exports to tighten global markets. 

"Potential issue of waivers on Iranian sanctions after Nov. 4 are both a key indication of the U.S. stance as well as a way to stem the ongoing unwanted rally in prices," the bank said. It said its base case for Iranian oil volumes remains for a loss of 1.5 million barrels per day.

(Reporting by Vijaykumar Vedala in Bengaluru Editing by Kenneth Maxwell) ((vijaykumar.vedala@thomsonreuters.com; +91-80-6749-6421 / 1298 (If within U.S. call 651-848-5832); Reuters Messaging: vijaykumar.vedala.thomsonreuters.com@reuters.net))