NEW DELHI — India accused Pakistan on Friday of orchestrating a suicide bombing that killed dozens of soldiers in Kashmir, the worst attack there in decades, promising an appropriate response and calling on world leaders to isolate its neighbor.

Pakistan has denied involvement in the attack, in which at least 40 Indian soldiers were killed Thursday when a driver slammed an explosives-packed vehicle into a paramilitary convoy. But by Friday afternoon, India had recalled its ambassador to Pakistan for consultations in New Delhi.

[On August 5, India revoked Kashmir’s special status.]

With national elections in India set to take place by May and Prime Minister Narendra Modi facing a close contest, analysts say he risks looking weak if he does not respond. Mr. Modi was elected in 2014 on promises to crack down on Kashmir’s militants and to adopt a tougher line on Pakistan. The nuclear-armed rivals have gone to war three times since independence in 1947, with two of the wars fought over Kashmir.

“We will give a befitting reply; our neighbor will not be allowed to destabilize us,” Mr. Modi said after an emergency meeting with security advisers on Friday, according to Reuters. “Our security forces are given full freedom” to respond, he added.