Menachem Mazuz said he took the decision to authorise the twice-delayed parade "so that freedom of expression is respected".
Hundreds of ultra-Orthodox Jews rioted in the city following the announcement, setting containers ablaze as policemen on horseback rode through the streets to stop them.
However, he called on the march's organisers to opt for "discretion" and to agree an "appropriate" route with police, in an apparent concession to opposition from ultra-Orthodox Jews, who have described the event as a "parade of debauchery".
Noa Sattath, chairwoman of gay rights group Jerusalem Open House, told Israel's Ynet News web site: "The decision sends a clear message to inciting sources who make cynical use of violence and terror to change the political reality."
Mazuz did not approve of the organisers' planned date for the parade of next Friday, saying only that it would take place "soon".
Police said they had briefed the attorney general on the likely public order implications of the event following a series of clashes between ultra-Orthodox demonstrators and police in recent days.
"Three police were wounded and 30 people arrested during clashes with ultra-Orthodox demonstrators in Jerusalem this week," said Micky Rosenfeld, an Israeli police spokesman, adding that police planned to deploy 10,000 officers for the parade.
Following the last Gay Pride event in Jerusalem last year, an ultra-Orthodox Jew was sentenced to 12 years in prison after he stabbed three participants.
Despite the hostility to such events in Jerusalem from Christian, Muslim and Jewish communities, gay pride marches are held in the commercial capital Tel Aviv each year without controversy.