Gap, one of the largest operators of mall stores in the United States, said on Thursday that it planned to spin off Old Navy into a separate public company, drawing a line between the family-friendly apparel chain and its classic, more expensive brands.

The separate company would contain Gap’s namesake label, Banana Republic, Athleta, Intermix and its new Hill City brand. Gap is aiming to complete the transaction in 2020, and the two companies will end up similar in size. Old Navy brought in about $8 billion in revenue in the last fiscal year while the brands that will make up the new entity combined to take in around $9 billion.

Art Peck, Gap’s chief executive, said on an earnings call that the proposed split was an opportunity “to write the next chapter for specialty retail.” He said that, over time, Old Navy’s needs have differed from those of the rest of the brands. It shares fewer customers with the other labels, has a smaller international footprint and uses different in-store technology.

“Old Navy is a little bit more fast-fashion, move quick, lower price point,” said Greg Portell, lead partner in the global consumer and retail practice of A. T. Kearney, a consulting firm. “If you think about the more mall-based brands, they are foundational, they’re classic, they’re not as quick to turn. Athleta’s a little bit different, but it still targets that consumer that is looking for a different experience than the Old Navy, price-based, go-now shopper.”

He added: “A lot of people are going to have different opinions on how much sense it makes. In a sense, by splitting the two, they’re allowing investors to put their money behind the company they feel has the best strategy to execute.”

Shares of Gap jumped more than 20 percent in aftermarket trading following the announcement.

Gap, based in San Francisco, created Old Navy in the early 1990s as a less expensive version of itself. It has since become the company’s biggest revenue generator. But the company said that as Old Navy had expanded, its business had become distinctly different from that of Gap’s other labels.

“Old Navy’s value-creation levers, business model and customers have increasingly diverged from our specialty brands,” Mr. Peck said. “That divergence to me is now clear, and we think the best way for each company to grow and meet the evolving needs of our customers is to allow them to pursue tailored strategies separately.”

Under Gap’s plan, Mr. Peck would be the chief executive of the new company, while Sonia Syngal, the president of Old Navy, would be that company’s chief executive. It is not yet clear what role the Fisher family, which founded Gap Inc. and still holds several board seats at the company, including chairman, would play at the new entities.

Mr. Peck also said that the new company could become the biggest publicly traded B Corp, a status certified by a nonprofit organization called the B Lab for companies that commit to uphold high social and environmental standards.

Gap made the announcement as it reported dismal financial results, particularly for its namesake brand. Gap’s comparable sales declined 5 percent in the past year compared with increases at Old Navy and Banana Republic, the company said. It also said that it planned to close about 230 Gap stores in the next two years, as it aims to find the right balance between sales online, in its regular stores and from outlet locations.