Google CEO Sundar Pichai speaks during the Google I/O keynote session at Shoreline Amphitheatre in Mountain View, California on May 7, 2019.

Google has agreed to pay 500 million euros ($550 million) in France in connection with a fiscal fraud probe.

French financial prosecutors opened an investigation into the company's tax dealings four years ago. Investigators were probing the company to determine if it evaded taxes by failing to declare the full extent of its activities in the country.

Shares of Google closed up 1.2% on Thursday.

A Google spokesperson said the settlement brings an end to tax and related disputes that have "persisted for many years."

"The settlements comprise a €500 million payment that was ordered today by a French court, as well as €465 million in additional taxes that we had agreed to pay, and that have been substantially reflected in our prior financial results," the spokesperson said in a statement. "We continue to believe that the best way to provide a clear framework for companies that operate around the world is co-ordinated reform of the international tax system."

Google, Apple and other U.S. tech giants have long taken advantage of a loophole that allows them to report almost all their sales in Ireland, which offers corporations low tax rates. This often results in them paying little taxes in other European countries.