Mr Garzon strongly denies that his investigation broke the law
Spain's most famous judge has testified in the Supreme Court over claims that he overreached his judicial powers.
In October 2008 Baltasar Garzon launched a controversial inquiry into atrocities committed during the four-decade rule of Gen Francisco Franco.
The court is hearing a complaint by a right-wing group that the judge knowingly exceeded his official remit.
In the past, the judge's indictments have targeted the likes of Augusto Pinochet and Osama Bin Laden.
Mr Garzon was met by a small crowd of supporters as he arrived at the Madrid courtroom, among them veterans of the civil war.
Gervasio Puerta, 88, who spent eight years in prison after fighting against Franco, told the AP news agency: "It is an injustice to try a person who wants to defend those of us who suffered under Franco."
In a blaze of publicity last October, Mr Garzon pledged to investigate what he called "crimes against humanity" committed during the Franco era.
Campaigned for extradition of former Chilean military ruler Gen Augusto Pinochet from UK to Spain over human rights abuses in 1998. Request turned down on health grounds
Charged Osama Bin Laden over 9/11 attacks in 2003
Tried unsuccessfully to prosecute Italian politician Silvio Berlusconi on charges of tax fraud and breaching anti-trust laws in Spain through stake in Spanish TV company Telecinco
He ordered several mass graves to be reopened to investigate the disappearance of more than 100,000 people during and after the 1936-39 Spanish Civil War.
But the inquiry was shelved following opposition from state prosecutors and his fellow judges.
Right-wing group Manos Limpias, or Clean Hands, alleges that he was not entitled to ask government departments to hand over papers from the Franco period.
The group's president, Miguel Bernad, said the hearing showed all were equal before the law.
"It is the first step for the processing of the superstar Baltasar Garzon who believed himself above the law," he said.
"I believe that the victory is for all the Spanish society."
The Association for the Recovery of Historical Memory, which seeks to identify those who disappeared in the Franco era, said the case was "grossly unjust".
Investigated - and cleared - for failing to declare pay received from US university during paid 2005-6 sabbatical
Fined $450 for administrative oversight which forced him to free two drug-traffickers from prison
Forced to drop case against Gen Franco and allies after jurisdiction questioned
"It is incomprehensible that an attempt to seek justice for victims of rights violations as serious as those committed by the Franco dictatorship can be considered a crime," AP quoted the group as saying.
"For victims of Franco, it is a humiliation to see that the judge who tried to find thousands of (the) disappeared in mass graves could be convicted for it."
Mr Garzon strongly denies that he broke the law, and has the backing of the International Commission of Jurists, which says his short-lived inquiry did not justify disciplinary action, let alone criminal prosecution
Roisin Pillay, a senior legal adviser for ICJ, said the prosecution of judges for carrying out their professional work was "an inappropriate and unwarranted interference with the independence of the judicial process".
The BBC's Steve Kingstone in Madrid says it would be a major surprise if this crusading judge was to be charged with a crime.
But his very appearance in court offers yet more evidence of how a dark past, seven decades old, continues to divide the Spain of today, our correspondent says.