Ireland is known for awesome pubs and a deep talent pool of programmers but that isn’t what has attracted some of the largest technology companies to the region. Leaders in Ireland have revealed plans to eliminate the controversial tax loophole responsible for bringing companies like Apple, Facebook Google and Microsoft to the country.

The scheme, often referred to as the “Double Irish,” allows corporations that have operations in Ireland to make royalty payments for intellectual property to a separate subsidiary registered in Ireland but physically located anywhere in the world which means, somewhere with a favorable tax rate.

As The New York Times explains, one example of this is Google who has a headquarters in Ireland staffed by 2,500 employees. A Google subsidiary in Ireland generates revenue then pays it as royalties to a separate Google unit in Ireland which is resident in Bermuda for tax purposes.

In layman’s terms, these massive tech companies all take advantage of this loophole in order to save what is likely billions of dollars in profits.

In a budget speech given to the Irish Parliament on Tuesday, Finance Minister Michael Noonan said he was abolishing the ability of companies to use the “Double Irish” by changing residency rules to require all companies registered in Ireland to also be tax resident.

The changes will go into effect starting January 2015 for new companies. Those already operating under the scheme will enjoy a transition period that lasts until the end of 2020.