Robert Downey Jr. decided to stop playing Iron Man because he felt it was the right time to move on from the role. After portraying Tony Stark/Iron Man for over a decade in the Marvel Cinematic Universe, he expressed a desire to explore other projects and not be confined to a single character. Additionally, the storyline in "Avengers: Endgame" provided a fitting conclusion to Tony Stark's arc, making it a natural point for Downey to step away from the role.
While financial considerations may have played a role, Robert Downey Jr. has stated in interviews that his decision to leave the role of Iron Man was not solely motivated by money. He emphasized the importance of artistic growth and the desire to take on different creative challenges as factors influencing his decision. While the financial aspect is undoubtedly a factor in any actor's career decisions, Downey highlighted the broader reasons for moving on from the iconic role of Iron Man.