TORONTO -- Canadian merchants may soon start charging customers extra to pay with certain credit cards thanks to a settlement agreement in a class action suit.

The suit, which was filed in 2011, alleges that Visa and MasterCard rules forced merchants to accept all their credit cards, even ones that charged retailers higher fees. Those rules did not allow merchants to add a surcharge for customers who use these premium cards.

In 2013, a regular VISA card, for example, charged merchants a 1.64 per cent fee, while a premium one charged 2.13 per cent, according to rates compiled by the Canadian Federation of Independent Business. That same year a regular MasterCard, for example, charged 1.69 per cent, while a premium one charged 2.39 per cent. The rates were based on preferred total merchant rates for CFIB members with Chase Paymentech.

In 2014, after discussions with the federal government, Visa and MasterCard agreed to voluntarily reduce the fees for five years.

Both companies released statements saying they do not admit to any wrongdoing in the class action, but entered into a settlement agreement earlier this week.

Visa and MasterCard agreed to pay $19.5 million each and allow Canadian merchants to add surcharge fees on credit card payments. The revised rules will include a surcharge cap.

Visa said in a statement that the new rules will come into effect 1.5 years after provincial courts in British Columbia, Alberta, Saskatchewan, Ontario and Quebec approve the settlement.

The CFIB praised the decision, saying it's important for merchants to have the power to add a surcharge when customers pay with premium credit cards. The CFIB added it does not expect smaller merchants to widely use this new power.