Sears Holdings, Kmart’s parent company, filed for Chapter 11 bankruptcy protection on October 15.

The company says it will close 142 stores before the end of the year, and its CEO, Eddie Lampert, has stepped down. Lampert is staying on as chairman and is reportedly in talks with at least one potential partner about sharing the burden of a $300 million bankruptcy loan for the company.

Sears has been closing stores and selling off assets following years of crippling sales declines. The company operates 687 Sears and Kmart stores, according to its bankruptcy filing. That’s down from nearly 2,000 stores in 2013.

This isn’t the first time Kmart has faced bankruptcy. In 2002, it filed for Chapter 11 bankruptcy protection before merging with Sears in 2005. At the time, it was the largest retail merger ever. The combined company’s sales have plummeted since then, dropping from $53 billion in 2006 to less than $17 billion last year.

Before things started going downhill, Kmart had thousands of stores across the US.

Here’s how Kmart ended up where it is now:

1/17

The first Kmart discount store was opened in Garden City, Michigan, in 1962 by the S.S. Kresge Company.

The first Kmart discount store was opened in Garden City, Michigan, in 1962 by the S.S. Kresge Company. AP Photo

Source: New York Times

2/17

In its first year, 17 more Kmart stores opened, and sales were upwards of $483 million.

In its first year, 17 more Kmart stores opened, and sales were upwards of $483 million. Business Insider/Jessica Tyler

Source: New York Times

3/17

S.S. Kresge, the company that started Kmart, changed its name to the Kmart Corporation in 1977.

S.S. Kresge, the company that started Kmart, changed its name to the Kmart Corporation in 1977. Getty Images

Source: New York Times

4/17

By 1981, there were 2,000 Kmart stores across the country.

By 1981, there were 2,000 Kmart stores across the country. Getty Images

Source: New York Times

5/17

Kmart spent the 1980s and 1990s buying various retailers, including Waldenbooks, Builders Square, PayLess Drug Stores Northwest, PACE Membership Warehouse, Borders, and Sports Authority.

Kmart spent the 1980s and 1990s buying various retailers, including Waldenbooks, Builders Square, PayLess Drug Stores Northwest, PACE Membership Warehouse, Borders, and Sports Authority. Getty

Source: New York Times

6/17

In 1990, Walmart passed Kmart in sales, knocking Kmart down to the third largest retailer.

In 1990, Walmart passed Kmart in sales, knocking Kmart down to the third largest retailer.