The Public Prosecution Service (PPS) said Mr Wells would not be charged in connection with the incident on 23 April in Downpatrick.
Mr Wells welcomed the decision as "an important step forward".
In a statement, the PPS said it was decided that the case did not meet the test for prosecution.
"Following a careful consideration of all the available evidence provided to the PPS by the PSNI, it has been decided that the case does not meet the test for prosecution," the PPS statement said.
"Potential offences were considered under the Public Order (NI) Order 1987, in particular an offence under article nine (stirring up hatred).
"Included in the evidence examined by prosecutors was a 30 second video clip which was widely circulated on social media after the event was staged in Downpatrick.
"The police also provided a longer transcript of a recording of the entirety of the man's comments.
"On examining the available evidence for the incident reported, in particular the entirety of the transcript of the man's comments, it was concluded that there was insufficient evidence to prove that any offence was committed."
In a statement, Mr Wells said he had been "vindicated" by the decision.
"This matter has been hanging over me for some time and so I am obviously delighted to have the air cleared," he said.
"It was seized upon by opponents of myself and my party and used against us in an entirely unreasonable manner.
"There are many aspects of this incident, and the subsequent campaign, that continue to raise significant cause for concern and which merit further investigation."
The DUP MLA Jim Wells will not be prosecuted for comments he made about gay marriage during a hustings event for the Westminster election.