BARCELONA, Spain — Lionel Messi has told Barcelona he wants to leave the club after nearly two decades with the Spanish giants.

The club has confirmed that the Argentina great has sent a note expressing his desire to leave.

The announcement comes 11 days after Barcelona’s humiliating 8-2 loss to Bayern Munich in the Champions League quarterfinals, one of the worst in the player’s career and in the club’s history.

The defeat capped a difficult season for Barcelona — the first without a title since 2007-08 — and ignited one of its worst crises ever.