Intimidating parliamentary candidates could become a specific offence under new plans aimed at curbing torrents of abuse hurled at public figures.
The Prime Minister's independent ethics watchdog also said social media giants should be fined or prosecuted if they fail to take down racist, extremist or child sex abuse content amid concerns over the "intensely hostile online environment".
Theresa May commissioned the inquiry into intimidation of parliamentary candidates in July after MPs of all parties spoke out over the barrage of death threats and hate-filled abuse they were subjected to on social media during the election campaign.
In the new report, the Committee on Standards in Public Life urged ministers to consider overhauling electoral law to make it an offence to harass campaigners and MPs, many of whom have already beefed up their security after the murder of Labour MP Jo Cox last year.
Social media was pinpointed as the main driver of the rise in abuse and harassment against MPs during the campaign, with many facing threats of violence and sexual abuse, as well as racist and misogynist slurs.
The influential committee recommended new laws to make Internet giants liable if they host criminal content - instead of the individual user, echoing concerns held by ministers that tech firms are too slow in ridding their sites of extremist material.
Web giants are not currently liable due to a European Union directive which treats them as "hosts" of online content but this could change after Brexit when the Government will be able to bring in new laws to make companies responsible, the watchdog said.
Political parties should also band together to create a new code of conduct on intimidation by December 2018, which would be jointly enforced, it added.
Committee chairman Lord Bew said: “This level of vile and threatening behaviour, albeit by a minority of people, against those standing for public office is unacceptable in a healthy democracy.
"We cannot get to a point where people are put off standing, retreat from debate, and even fear for their lives as a result of their engagement in politics.
"This is not about protecting elites or stifling debate, it is about ensuring we have a vigorous democracy in which participants engage in a responsible way which recognises others’ rights to participate and to hold different points of view.
“The increasing scale and intensity of this issue demands a serious response. We are not alone in believing that more must be done to combat online behaviour in particular and we have been persuaded that the time has come for the government to legislate to shift the liability for illegal content online towards social media companies, and to consult on the introduction of a new electoral offence."
Lord Bew, who was appointed a life peer for his contribution to the Northern Ireland peace process, said party leaders had to get tough with members who engage in "appalling behaviour" as all sides had failed to address the issue properly during the recent campaign.
Politicians must do more to support black and ethnic minority, LGBT and female candidates who are likely to suffer the most abuse, the report found.
Shadow Home Secretary Diane Abbott received levels of racist and sexist abuse which amounted to nearly half of all abuse directed at female MPs, according to research which tracked more than 25,000 tweets sent to parliamentarians over a six-month period.
Conservative Party chairman Patrick McLoughlin said: "This is a welcome but hard-hitting report, that rightly highlights how public figures are routinely subject to unjustifiable abuse, fuelled by social media. Those running for public office should be held to account at the ballot box and in the media, but such online abuse ultimately undermines free speech and weakens our democracy.
“The Government, Parliament and political parties should now consider the report's recommendations carefully. I hope there are a number of areas where there can be an emerging consensus for action - including greater transparency on online campaigning, proper intervention by social media companies, and effective enforcement of criminal law.”