Rajoy has rejected calls to resign over the scandal implicating his Popular Party as he fights to pull the eurozone's fourth-biggest economy out of a deep recession.
The pressure on him increased over the past week with fresh revelations linked to Luis Bárcenas, a former treasurer of the party who is under investigation over allegations that he channelled payments to Rajoy and other party leaders.
Bárcenas told the court investigating the allegations that he had handed Rajoy €25,000 euros in cash in 2010. Rajoy has denied any wrongdoing and said he would not resign.
"If a person as relevant as the prime minister gets implicated in undeclared payments in cash, it is necessary for him to testify before the judge," as a witness, said one of the groups bringing the case in court, lawyers' association ADADE, in a statement.
Another civil party in the case, the extreme-right group Manos Limpias, echoed the call in a separate statement.
As a member of the government, Rajoy has the right under Spanish law to submit testimony in writing instead of appearing in court if he is summoned as a witness.
He has so far resisted calls by opposition lawmakers to answer questions on the scandal in parliament.