The Italian coach had made the explicit gesture after being spat at by Hertha fans during Bayern’s 1-1 draw in Berlin on Saturday.
The DFB said it had closed the case against Ancelotti “on condition the Bayern Munich coach makes a 5,000-euros ($5,270) donation to the Sepp-Herberger Foundation”, the federation said in a statement on its website.
The foundation — named after the coach of the West Germany team that won the 1954 World Cup — is an association run by the DFB to provide opportunities for handicapped footballers and to help former prisoners reintegrate into society.
Bayern had publically backed their coach after his gesture, saying: “Essentially, we find emotionally understandable the human reaction that drove Carlo Ancelotti to make this gesture, as a response to this vile attack.”
On Monday, the DFB had invited Ancelotti to explain his actions — the Italian had already admitted his guilt to German television station ARD after the match.
Tensions were high during the match, in which Bayern, whose players had been jeered throughout, equalised six minutes into added time.
Download our app and read this and other great stories on the move. Available for Android and iOS.