Ansari urged the leaders of both countries to work towards a peaceful resolution to the conflict.
''Indian forces had arrived in Kashmir as a security force, but gradually became an occupying force'' he said.
Ansari said that both countries would gain nothing from continuing with the confrontation that started since their independence from Britain in August 1947.
''Indian forces arrived in Kashmir as a security force, but gradually became an occupying force''
Molvi Abbas Ansari
Ansari asked both countries to respect '' the urges and aspirations of Kashmiri's''.
More than 39,500 people have died since an insurgency against Indian occupation, according to official figures. Separatists put the death toll closer to between 80,000 and 100,000.
Indian forces arrived in Muslim majority Kashmir on 27 October 1947, after the Himalayan region's Hindu ruler requested their help to fend off Pakistani backed tribesmen.
After Indian troops landed in Kashmir, Prime Minister Jaqaharlal Nehru promised that Kashmiri's would be able to decide whether they wanted to stay with India or become part of Pakistan.
A UN Security council was passed to ensure that Kashmiri's would be able to determine their own future and decide who they wanted as their rulers.
India considers the resolutions to be absolute and wants agreement with Pakistan to support a crackdown on resistance activity in the country.