Pastor James McConnell called the religion "satanic" and a "doctrine spawned in hell" during a sermon broadcast online.
He had always maintained it was his right to free speech and a judge has agreed.
Delivering his verdict, District Judge Liam McNally said: "The courts need to be very careful not to criminalise speech which, however contemptible, is no more than offensive. It is not the task of the criminal law to censor offensive utterances.
"Accordingly I find Pastor McConnell not guilty of both charges."
He added: "If he had clarified this in his sermon and set out in a clear and precise way why Sharia law was repugnant to him he could have saved himself a lot of trouble."
The 78-year-old faced two charges - improper use of a public electronic communications network and causing a grossly offensive message to be sent by means of a public electronic communications network - after the comments made from the pulpit of his Whitewell Metropolitan Tabernacle on May 18 2014 were streamed online.
During the case, the judge was shown a dvd recording of the entire religious service during which the controversial sermon was made, including gospel singing, scripture reading and prayer.
In it McConnell also said he did not trust Muslims.
Prosecutors said the pastor was not on trial for his beliefs but alleged the "straightforward" case centred on his carefully chosen words which they claimed were "grossly offensive".
Giving evidence in his defence, McConnell said he had not intended to provoke, hurt or offend Muslims but was unrepentant for preaching the gospel.
He also revealed that he had turned down a lesser punishment of an informed warning because he did not want to be "gagged".
Several hundred evangelical Christian supporters attended each day of the hearing to show solidarity with McConnell.
Peter Lynas, national director of the Evangelical Alliance Northern Ireland, said: "Today's verdict is a victory for common sense and freedom of speech. However, until the law is changed or clear guidance is issued, there will still be concern about further prosecution.
"The Public Prosecution Service need to explain why this case was brought and assure everyone that this will not happen again.
"This case contains challenges to both the State and the Church. It is vital that the State does not stray into the censorship of church sermons or unwittingly create a right not to be offended.
"Meanwhile, the Church must steward its freedom of speech responsibly, so as to present Jesus in a gracious and appealing way to everyone."
When considering the remarks about mistrusting Muslims, Judge McNally said he had taken the preacher's good character into account.
He added: "He is a man with strong, passionate and sincerely held beliefs. In my view Pastor McConnell's mindset was that he was preaching to the converted in the form of his own congregation and like-minded people who were listening to his service rather than preaching to the worldwide internet.
"His passion and enthusiasm for his subject caused him to, so to speak, 'lose the run of himself'."
Outside court, hundreds of supporters cheered as Pastor McConnell emerged.
Some sang hymns as the preacher gave his reaction to the judgment.
"I am very happy," he said.
He added that he give the sermon again, though he would word it differently.
"The only regret I have is the response from the Muslim community - that I was out to hurt them," he said.
"There was no way I was out to hurt them - I wouldn't hurt a hair on their head.
"But what I am against is their theology and what they believe in.
"If there are Muslims out there, I want to assure them I love them and, if they need help, I am there to help them, but their theology and their beliefs I am totally against them."
He added: "I would do it again but I would word it differently because I would be conscious I was hurting innocent Muslims, I would be conscious I was hurting Muslims who have come here to work hard and are doing their best - there's no way I would hurt those people, but I would do it again, yes."
Pastor James McConnell speaking to Premier's Hannah Tooley:
David Smyth, Policy Officer at the Evangelical Alliance in Northern Ireland, speaking to Premier's Hannah Tooley:
Senior Fellow in Islamic Studies at the Westminster Institute, Sheikh Dr Muhammad Al-Hussaini, speaking to Premier's Hannah Tooley: