Dollar Tree is buying its larger rival for $74.50 a share, 23% more than Family Dollar's closing price on Friday, for a total value of $8.5 billion.
Combined, the two chains have more than 13,000 stores and annual revenue of $18 billion. That would surpass the current leader in the dollar-store sector, Dollar General, which has more than 11,000 stores and revenue of $17.5 billion.
Dollar Tree plans to continue to operate both the Dollar Tree and Family Dollar brands. It expects the deal to close early next year.
A big winner in the deal is activist investor Carl Icahn, who holds 9.4% of Family Dollar shares, according to sales tracker LionShares. Icahn acquired most of the shares in the past year.
Shares of the company shot up in June when Icahn disclosed his stake, but have given back most of the gains since. The stock is down nearly 6% for the year through Friday's close.
Copyright 2016 Nexstar Broadcasting, Inc. All rights reserved. This material may not be published, broadcast, rewritten, or redistributed.