Until now, customers could find themselves locked in once the first three months of a deal had passed, unless they paid a penalty fee.
Under new rules, they will be able to walk away at any point, if certain conditions are met.
Ofcom's new chief Sharon White will outline details of the move.
In her first speech since taking the post, Ms White will say people still find it too difficult to cancel contracts and are often frustrated with customer service.
"When Ofcom was established, access to a reliable internet connection and mobile phone was a 'nice to have'," she will tell a conference hosted by the consumers association Which.
"Now it is essential to the functioning of the economy, to the way people work and live their lives."
Which's executive director welcomed the move.
"Unreliable broadband speeds drive consumers crazy, so we also welcome the regulator telling providers to give better information on the speeds customers will realistically achieve, and to let people leave their contracts without penalty if they don't get what is promised," said Richard Lloyd.
"This is an encouraging start by Sharon White at a time when there are very big challenges facing Ofcom."
The new rules apply to internet service providers (ISPs) using digital subscriber line (DSL) technology.
That means BT, EE, Sky and TalkTalk are all affected, but not Virgin Media, which uses a cable-based system.
When a customer signs up to a deal, an ISP must give a range of speeds a customer can expect - for instance 20 to 40 megabits per second.
However, there is an additional measurement the companies refer to less often: the minimum guaranteed access line speed (MGALS).
This represents the fastest download speed delivered to the slowest 10% of customers on a similar service.
For example, there might be 10,000 homes based 4km (2.5 miles) away from the local telephone exchange.
If the fastest speed achieved by any of those in the 1,000 slowest properties was 7Mbps, that would represent the MGALS.
Until now, users could abandon their broadband contract without penalty within 90 days of its start if their home fell below the MGALS.
Under the revised code of practice, they can do so at any time, so long as they have given the provider a "reasonable" opportunity to fix the problem - for example a few weeks of time and access to their building.
The challenge for the public will be to determine if indeed their property falls below the cut-off point.
One expert said the move should benefit a "small percentage" of users, but said he still had concerns.
"The problem for the consumer is understanding whether switching provider will fix the problem," said Andrew Ferguson from the ThinkBroadband news site.
"If you switch and the new provider is using the same technology as the previous one, and the slow speeds are due to the line, then you may just carry on having the same issue."
Ofcom can fine companies if they break the rules, but suggested individuals initially direct their complaints to including the Communications and Internet Services Adjudication Scheme (CISAS) or the Ombudsman Services.
"We have set the bar high for ourselves but also for industry," Ms White will say.
"If we deliver then everyone benefits: consumers and citizens of the country and the businesses who deliver the services we regulate."

In total 14 tents were targeted, with cash, mobile phones, electrical items and credit cards stolen.
The incidents took place in the Green Camping Area of the Dundrennan site in the early hours of Sunday.
Police are keen to hear from anyone who may have seen or heard anything suspicious in the area at the time.
However, they praised the public in general for their good behaviour during the event.
Police said said there were "only a few matters of minor disorder" reported and no cases of serious disorder or violence.
There were 46 cases of drug possession and two cases relating to drug supply detected.
Insp Stuart Davidson said:  "We want to thank those who attended the festival for their generally good behaviour, and co-operation with the police and other agencies involved in the security and wellbeing of all those on site over the weekend.
"We have developed good working relationships with the organisers over the years and this experience helped towards a professionally-run event.
"I would also acknowledge the excellent standard of the security and stewards who assisted us over the weekend."
The broadband industry's watchdog has announced new rules to help subscribers quit their contracts if their speeds are too slow.
[NEXT_CONCEPT]
Police are investigating a spate of thefts on the Wickerman Festival site which were carried out while tent owners were sleeping.