The draft law still requires the final approval of the European Parliament and member states, which are expected to decide on it early next year so it could come into force around March or April.
Energy Commissioner Günther Oettinger said the political agreement was already a major step forwards.
"This is really a breakthrough and will give a big push to much-needed infrastructure," Oettinger said.
"Rather than waiting up to 12 years or longer for a permit, developers of crucial cross-border infrastructure – such as pipelines or power grids – will have a decision in about 4 years."
The Commission had proposed permit-granting for crucial infrastructure should not exceed three years, but a deal reached on Tuesday had decided on a maximum timeframe of three years, six months, the Commission said in a statement.
Environmental groups have raised concerns that faster approvals could lead to infrastructure being placed in environmentally sensitive areas.
But the Commission sees only advantages and says EU citizens will still be given the chance to raise objections.
It says faster approvals will cut administrative costs, as well as moving the bloc closer towards a single energy market.
The European Commission has said enforcing a single energy market is a priority to encourage the equitable flow of power and gas across borders to stimulate competition, help to reduce prices and make supplies more secure.
To enforce it, it has been cracking down on member states that have failed to enforce relevant law and it is also seeking to spur huge amounts of investment in infrastructure that can benefit more than one country.
The fast-track permitting rules will only apply to the most strategic infrastructure, labelled "projects of common interest" because they benefit more than one member state.
They could include, for instance, the proposed southern corridor route to bring gas supplies from Azerbaijan and reduce dependency on Russian gas.
The European Union is expected to decide on the projects of common interest next year.
They could be entitled to funding from €9.1 billion towards strategic energy infrastructure proposed by the Commission as part of the bloc's seven-year budget, which the European Union has so far failed to agree.
That compares with the estimated €200 billion the Commission has said is needed to build gas pipelines and new power grids.