Fame came at a price for a Spanish boy who mistakenly racked up €100,000 (£88,000/US$112,000) in advertising fees with Google as he attempted to make his brass band famous online.

But the search company said it would waive his exorbitant bill after realising the 12-year-old had made a costly “mistake”.

In August, Jose Javier from the south-eastern seaside city of Torrevieja created an account with AdWords, a Google pay-per-click service that puts ads above search results and on other sites.

The customer gives his or her credit card details and only pays when someone clicks on the link.

Javier – whose parents had opened a savings account in his name – gave his banking details thinking he was actually going to earn money from ads on his homemade website.

The company realised that “it was all a mistake and that he did it without thinking”, a Google spokeswoman said on Wednesday.

“A 12-year-old boy doesn’t want to start spending €100,000.”

In a statement the company added it would waive the boy’s debt.

His mother, Inma Quesada, told the El Pais daily that her son “wanted to buy instruments” for his band Los Salerosos, loosely translated as The Salties, in which he plays the trumpet.

His parents were alerted to the fact that he was racking up debt when the bank called them to warn them about the charges.