After 137 years, 10 architects, and millions of euros of administrative costs, Barcelona’s modernist masterpiece the Sagrada Família has finally been granted a building permit.

In what has been satirised as the ultimate tale of sluggish bureaucracy, Barcelona City Hall gave the belated go-ahead for the construction of the basilica on Friday, following a provisional agreement last October.

The Sagrada Família Foundation said that the licence would allow it to “continue to build Antoni Gaudí’s project”, expected to be completed in 2026, coinciding with the centenary of the death of its main designer.

The cathedral now has legal approval for ongoing works to restore and expand the existing structure, with a budget of 374 million euros (£332.5 million). The licence itself cost 4.6 million euros (£4.1 million).

The construction board will also have to pay 36 million euros (£32 million) over 10 years to cover public costs incurred by its activity.