It is very widely felt that Sri Shankaracharya was instrumental in driving the Buddhism out of India. We need to see if this is entirely true or how much.
Buddhism which came into existence by 6th century BC continued to rise even after the demise of Buddha. It saw its peak during the regime of Mauryas, especially Asoka (4-3rd century BC) during which period the Buddhism was all pervasive in India and even a political power to reckon with. Soon after Mauryas, probably the religion started fading out very slowly. Chinese travelers like Fa-Hien (early 5th century AD), Xuanzang (early 6th century AD) note with concern that Buddhism was on a sharp decline in many parts of India. Shankaracharya's came much later, that is 9th century AD.
By the time of Sri Adi Shankara, the Buddhism in India was no more than another a major community and just a theoretical opponent for the Sanathana Dharma. It was no more a big political or religious power to reckon with. It was already on its way out, not because of Shankara, but due to many other politico-religious and economic reasons (and it had more reasons stored in the future in the form of various invasions).
By the time of Shankara, India was in the shape of a religiously looted house, from the point of view of Sanathana Dharma. Buddhism had lost its sheen and had already become highly devoid of all the great ideals taught by the Buddha. 1500 years of its reign in India had certainly created a deep impact on Indian psyche (both in positive and negative ways). But since Buddhism was no more a religion of power now, the Buddhists were helpless, powerless and by and large disillusioned. On the other hand, the followers of Sanatana Dharma had long forgotten the noble way shown by the Upanishats and had confined themselves scrupulously and stubbornly to the ritualistic parts of the Vedic scripture. Those who did not like this but still not embraced the Buddhism had a kind of appreciation towards Buddhism, at least in principle, due to many of its appealing principles like non-violence, no-sacrifice etc. Many sects like Vaishnavaites had already abandoned Vedic sacrifice etc and adopted a life of non-violence and vegetarian life style. Thus the mass, (Buddhist and Sanathani mass all alike) had lost belief in their respective religions. The Sanathana Dharma was crumbling under its own weight. This was the situation that needed a leader who could revive Sanathana Dharma from the clutches of ritualistic approach and show the people the noble path of divine knowledge.
This was the socio-religious scene when Shankara stepped into picture. He had a big task of harmonizing the Hindu scriptural preaching with the moral conscience of the masses. Buddha's principles and teachings appeared quite appealing, including those that deal with fallacy of world, the cycle of karma, trap of desires, the principle of live and let live etc. It seems even Shankara was quite impressed with these principles, why not? They are universally appealing. But there was a problem. Buddha squarely rejected the supreme authority of the Vedas. On the other hand, Sri Shankara’s belief and conviction about the Sanathana dharma, and its eternal goodness was firm. He firmly believed even the Vedic scriptures (upon which the Sanathana Dharma relies) ultimately taught those very principles. He believed that this noble vision was only covered behind the thick veil of mundane rituals. To reform this would mean a bitter debate with the Sanathanis who stuck to their guns. This is where he had the challenge - of treading on the tight rope - of bringing about the reforms within the framework of Sanathana Dharma and its religious scriptures, the Vedas. This was a fine-balancing act. If you take a stand that Vedas were the ultimate authority, you would be upholding all that is told by the Vedas, even the so called "inhuman practices" prescribed by the Vedas; On the other hand, if you take a stand that the Vedas should be followed except where the practices are evil ones, it means you are not accepting the ultimate authority of Vedas (which was exactly the stand taken by Buddha) it will be a philosophy "outside" the framework of Sanathana Dharma). So a politically, diplomatically and philosophically correct and acceptable middle path was very much necessary.
Upanishats (also called Vedanta, as they are usually found to be the last of four classes of Vedic literature, i.e., Samhita, Brahmanas, Aranyakas & Upanishats) are a form of philosophical sublimation of the rest of the Vedas. They deal with the metaphysical and spiritual aspects of life such as Atma, Brahma etc rather than ritualistic codes and duties. Hence this part of Vedas is called "Jnyana Kanda". The rest of Vedas that deal with the worldly and ritualistic aspects of life are called "Karma Kanda". Many Vedic schools consider the Karma Kanda itself as the Veda proper, and they consider the Upanishats as only an abstraction and sublimation of the Vedas. Those who pursue the "Karma Kanda" are known as "Poorva Meemamsakas". For them it is only the Veda proper (i.e., Karma Kanda) is the ultimate authority, not the Upanishats. On the other hand there are others who consider only the Upanishats i.e., "Jnyana Kanda" as the ultimate authority. It is said when you enter the realm of supreme knowledge as preached by the Upanishads, the "lower level" ritualistic preachings become meaningless ("atra vedaH avedaa bhavanti"). This is the school of "Uttar Miasma". For them Upanishats are the only pramanas, not the rest of the Vedas.
Shankaracharya identified himself with this "Uttara Miasma" for three reasons:
One, after all, the meaning of all the rituals and all pursuits is ultimately the self realization which comes from the ultimate knowledge of the world and the Brahman. Once you have the knowledge you will realize the futility of all rituals, karmas, and life struggles; you will realize just how unreal the world is, and how you are nothing but an illusory image of the Brahman itself. This, he perceived, to be the view of the Upanishats.
Two, with this you will be doing away with the Karma Kanda, or at least do not consider it as an authority. Thereby all the "evil Vedic practices" like animal-sacrifice etc (which the Bouddhism had always been criticising) will stop even in Sanathana Dharma also (thereby making it as appealing as the Bouddha dharma that was in vogue).
Three, this reform will be well within the frame-work of Vedic scriptures (for Vedanta/Upanishats is nothing but a sublimation of the Vedas proper). It is significant to note that so called "advita" as we call it today was not the name given to it by Shankaracharya. He rightly calls his philosophy as "oupanishada darshana" (the darshana according to Upanishats - since he upheld the supremacy of Upanishats).
Then, who were Shankaracharya's main opponents? Not Buddhists, but the Sanathana Dharmis who still had faith in "Karma Kanda" i.e., the "Veda proper". Naturally Shankara had a lot of debates with the doyens of Poorva Mimamsa and other schools like Nyaya, Vaisheshika, Sankhya etc, apart from the already fading Bouddhas. Since Buddhism was never against Sanathana Dharma except in respect of meaning-less rituals etc, this new model of Shankaracharya which by and large resembled the Buddhist model of denial of world and karma, and yet "within the framework of Vedas" really appealed to people and scholars alike. This was the reason why Shankara was able to take the Indian philosophic arena by storm with his novel philosophy. He had as big an impact as the Buddhism itself and eventually filled the political and philosophical vacuum created by the exit of Buddhism in India.