In the roughest year for U.S. stock prices since 2008, Minnesota companies underperformed the broader market for the second straight year.

Major U.S. stock indexes, which rose in a range of 20 percent to 28 percent in 2017, finished 2018 with declines that ranged from 4 percent to 8 percent. The Piper Jaffray Minnesota index, a measure of about 50 large Minnesota-based companies and a few others with large operations here, fell about 10 percent.

The share value of about 30 of approximately 80 Minnesota publicly-traded companies finished higher for the year. The biggest gain occurred in shares of Surmodics Inc., the Eden Prairie-based maker of surface coatings for medical devices, which rose 70 percent. In September, before a broad swoon in the value of nearly all stocks, Surmodics shares were trading at nearly three times the level they started the year.

The shares of Minnesota's most-valuable company, UnitedHealth Group Inc., rose 11 percent and was one of the 14 in the 30-company Dow Jones industrials average to finish higher for the year. The Minnetonka-based insurer and health data services company closed the year with a market capitalization of $240 billion, more than twice the value of the state's next most-valuable firm 3M Co.

UnitedHealth passed 3M in market value just three years ago, ending the Maplewood-based manufacturer's decadeslong reign at the top. In 2017, 3M experienced a sizable jump in share value and, with UnitedHealth, Boeing and Caterpillar, led the gains in the broader Dow Jones average.

But in 2018, 3M shares fell 17 percent. The company, which does more business outside the U.S. than UnitedHealth and many other Minnesota companies, lowered its performance expectations in October after being stung by unfavorable currency foreign-exchange rates, sluggish demand in Europe and the broader trade war the U.S. started with China and other countries.

The three Minnesota companies that went public in the stock market this year experienced mixed results. Shares in Inspire Medical, the Maple Grove-based maker of an implantable medical device to treat chronic obstructive sleep apnea, have risen nearly 70 percent since trading began in May.

Ceridian HCM Holding Inc., the Bloomington technology services firm, saw a 19 percent increase in share value since its April listing. Meanwhile, Bridgewater Bancshares Inc., a St. Louis Park-based regional bank, experienced a 17 percent decrease in share value since listing in March.

The worst-performing stock in Minnesota in 2018 was CHF Solutions, the medical device company formerly known as Sunshine Heart, which saw an 85 percent decline in value. The company's stock was also the worst-performer in 2016. Among more-valuable companies, Evine Live, Christopher & Banks and Winnebago lost more than half their stock value in 2018.

Staff writer Patrick Kennedy contributed to this report.

Evan Ramstad • 612-673-4241