Spain international Casillas has featured just twice for Real since fracturing his hand in January, with Diego Lopez preferred by both Jose Mourinho and new manager Carlo Ancelotti.
The 32-year-old has enjoyed much success with Real in his career, winning five La Liga titles and two UEFA Champions League crowns.
Casillas is eager to stay and secure more silverware with the capital club, but revealed he could change his mind if he does not win back his first-team place.
"Players go through moments when if you are not playing a part you think about making some sort of decision," Casillas is quoted as saying by the Spanish media.
"Of course I want to stay here, winning more titles with Real Madrid.
"I have been here since I was a small boy but the day will come when maybe a decision will have to be made.
"I have decided I want to be part of this squad for a long time but if the situation doesn't change in three months and you ask me the same question perhaps I will answer that I am planning to leave."
Casillas was left out of Spain's 2-1 FIFA World Cup qualifying win over Belarus last Friday, but returned to Vicente del Bosque's side for the 2-0 victory over Georgia on Tuesday.
And the World Cup winner accepts that a guaranteed place in the national side for Spain's title defence may well depend on whether he can regain the number one spot at Real.
"Psychologically, you have to take the positive out of this," he added.
"Ancelotti's decision is the latest challenge, an abnormal situation and I want to win confidence.
"I will fight to get back into the starting XI. I want to play more. To play for your national team you have to be playing for your club."
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.