MILAN/LONDON (Reuters) - European shares rose on Wednesday, driven by the export-oriented autos and tech sectors, as optimism grew that the United States and China could avoid a full-blown trade war that would worsen the slowdown in the global economy.

FILE PHOTO: The German share price index DAX graph is pictured at the stock exchange in Frankfurt, Germany, January 7, 2019. REUTERS/Staff

The pan-European STOXX 600 .STOXX hit a three-week high in early deals before trimming gains to close 0.5 percent higher. Britain's FTSE 100 .FTSE touched a five-week high, ending the day up 0.7 percent, and Germany's DAX .GDAXI rose 0.8 percent.

“My scenario is that of an economic slowdown but I expect things to get gradually better following a brutal 2018 dominated by tariffs and very harsh commercial rhetoric,” said Roberto Lottici, fund manager at Italy’s Banca Ifigest.

Chinese and U.S. teams ended trade talks in Beijing on Wednesday after an extension.

But the U.S. trade representative’s statement underwhelmed investors, sending stocks to a session low.

The USTR office said China pledged to purchase “a substantial amount” of agricultural, energy and manufactured goods and services from the United States.

European equities recorded their worst year in a decade in 2018 but so far this year they are up three percent. A trade deal could make investors more upbeat over company earnings as the fourth quarter earnings season gets under way.

“From a technical standpoint, we do think the market was looking very very oversold as of two weeks ago which was giving a fairly good buy signal and I think that’s what’s happening now,” said Emmanuel Cau, head of European equity strategy at Barclays.

Autos .SXAP rose 2.4 percent, making them the biggest sectoral gainer. Shares in Daimler DAIGn.DE and BMW BMWG.DE, which both produce cars in the United States for the Chinese market, rose 3 and 1 percent respectively.

Fiat Chrysler FCHA.MI added 2.9 percent after a Reuters report said the Italian-American carmaker was nearing a settlement to resolve U.S. allegations in a diesel emission case.

Car parts makers Faurecia EPED.PA and Valeo VLOF.PA also climbed 6.4 and 5.8 percent.

Tech .SX8 stocks gained 2.2 percent as the upbeat mood around trade helped investors shrug off reports that U.S. tech giant Apple AAPL.O had cut planned first-quarter production for its three new iPhones.

The sector had already fallen sharply last week on the back of Apple’s first sales warning since the iPhone launch in 2007. A senior White House adviser said last week Apple sales should recover once Washington strikes a trade deal with Beijing.

Spain's IBEX .IBEX lagged peers, ending the day down 0.3 percent.

Telefonica TEF.MC was a big weight, down 1.8 percent after Costa Rican authorities raided the offices of two of its subsidiaries as part of an investigation into alleged tax fraud of at least $2 million.

Also falling was German telecoms firm 1&1 Drillisch DRIG.DE, down 6.5 percent after Macquarie cut their rating on the stock to "neutral".

“[Drillisch] may enter the German spectrum and capex spend cycle with an uncertain returns outlook,” analysts at the Australian bank wrote.

Dealmaking moved some shares.

French appliances firm SEB SEBF.PA shot up 10 percent to the top of the STOXX after it acquired U.S.-based coffee equipment maker Wilbur Curtis, with analysts saying the professional coffee machine segment was enjoying high profitability.

Italian peer DeLonghi DLG.MI was up 3.5 percent.

Elsewhere the focus was on earnings updates.

TGS TGS.OL shares hovered around flat after the Oslo-listed seismic surveyor posted a smaller-than-expected increase in quarterly revenues and cautioned on exploration spending this year.

Britain's No.3 housebuilder Taylor Wimpey TW.L jumped 6.2 percent after saying indicators for 2019 sales were solid.

Overall, fourth-quarter earnings for Europe are expected to have risen 7.1 percent on revenues up 4.5 percent, according to Refinitiv data.