Working for Goldman Sachs doesn’t pay like it used to.

The Wall Street behemoth slashed its average pay package by a fifth during the first quarter, as traders struggled with bad bets and the bank hired more lower-wage workers for its fledgling consumer bank.

The average Goldman employee earned $90,779.94 in total compensation and benefits during the first three months of the year — down sharply from $119,323.53 a year ago, the bank revealed Monday.

The nearly $29,000 pay gap comes as the bank’s profits overall fell by 21 percent, to $2.25 billion, as the powerhouse trading units struggled to make money as the government shutdown and China trade concerns weighed on markets.

The cuts in compensation helped Goldman offset some of its lousy results, including a 24-percent decline in revenue from stock trading, to $1.77 billion, and an 11-percent drop in bonds, currencies, and commodities, to $1.84 billion.

“While we aspire to bring stronger results, the overall franchise performed well,” Chief Executive David Solomon, who took the helm in October, said on an earnings call with analysts.

Solomon is trying to remake the bank by building out more stable — but less volatile — businesses like consumer banking and corporate cash management, while slashing some of its lagging commodity trading business.

As the bank pushes away from its traditional trading businesses, analysts expect that the total compensation will continue to fall in the coming years.

“The compensation numbers should be coming down,” Marty Mosby, analyst at Vining Sparks, told The Post.

The total pay includes salaries, deferred compensation like stock awards, and other benefits, like health care, said Goldman spokesman Michael DuVally.

One bright spot for the bank was a drop in money set aside for the giant Malaysian bribery scandal around the fund 1MDB, as well as other legal and regulatory costs. The bank spent $37 million in provisions for legal and regulatory proceedings, down from $516 million the previous quarter.

When asked by an analyst to explain where the bank was with 1MDB litigation — which some analysts expect could top $5 billion — Solomon declined to give any details about talks with the Justice Department or any of the other agencies or governments investigating the bank.

“We are on an evolutionary path,” Solomon said.