The money will go to the Cancer for College foundation run by a fraternity brother of Ferrell's at the University of Southern California. The $47,100 high bidder, a man from Dallas, asked to remain anonymous. The opening bid was $5,000.
"Winning this auction means a lot to me on a very personal basis," the winner said in a statement released by the foundation. "I lost my mother to ovarian cancer a few years ago, so I feel fortunate that my 10-year-old and I are able to participate in an event involving Cancer for College and Will Ferrell."
Ferrell came up with the idea to auction off a non-speaking part as an extra in his new movie, "Step Brothers."
"We are overwhelmed with the response and generosity to the auction," Ferrell said. "This money will help so many young people with their dreams of attending college."
The winner is scheduled to meet Ferrell on Friday at the 14th annual Cancer for College golf tournament dinner in Temecula, then join the actor on the movie set next month.
Ferrell's friend Craig Pollard, a two-time survivor of Hodgkin's disease, started Cancer for College to provide scholarships to current and former cancer patients. The charity has awarded $200,000 to 50 cancer survivors since 1993.