NEW YORK — A New York regulator is investigating Goldman Sachs for possible sex discrimination in the way it sets credit limits. The bank denies wrongdoing.

The investigation follows a series of viral tweets by entrepreneur and web developer David Heinemeier Hansson about algorithms used for the Apple Card, which Goldman Sachs manages in partnership with Apple.

Hansson said the card offered him a credit limit 20 times greater than it gave to his wife, even though she has a higher credit score. He called the algorithm a sexist program.

A New York regulator says it is investigating Goldman Sachs for possible gender discrimination in the way it sets credit limits for the Apple Card. Michael Short / Getty Images file

Apple co-founder Steve Wozniak also made a similar claim, tweeting that he received 10 times more credit on the card than his wife.

A spokeswoman for the New York Department of Financial Services confirmed Saturday that the agency will investigate.

The agency is "troubled to learn of potential discriminatory treatment in regards to credit limit decisions reportedly made by an algorithm of Apple Card, issued by Goldman Sachs," said spokeswoman Sophia Kim. She said the department "will be conducting an investigation to determine whether New York law was violated and ensure all consumers are treated equally regardless of sex."

The same thing happened to us. We have no separate bank accounts or credit cards or assets of any kind. We both have the same high limits on our cards, including our AmEx Centurion card. But 10x on the Apple Card. — Steve Wozniak (@stevewoz) November 10, 2019

"Our credit decisions are based on a customer's creditworthiness and not on factors like gender, race, age, sexual orientation or any other basis prohibited by law," said Goldman Sachs spokesman Andrew Williams. He added that the bank could not comment on decisions about individual customers.

Apple did not immediately respond to a request for comment.

In several tweets that were often liked thousands of times and frequently retweeted, Hansson didn't disclose his or his wife's income, but wrote that they have been married a long time, file joint tax returns and live in a community-property state. He tweeted that appeals when she got a far lower credit limit fell on deaf ears.

When Apple Card finally raised her credit limit without addressing the scoring system, he tweeted, it was essentially trying to "bribe one loud mouth on Twitter, then we don't have to actually examine our faulty faith in THE ALGORITHM."

Apple introduced the Apple Card earlier this year in a partnership with Goldman Sachs. A press release announcing the card called Goldman Sachs "a newcomer to consumer financial services" that was "creating a different credit card experience." It pledged not to share or sell information to other parties for marketing and advertising.

"Simplicity, transparency and privacy are at the core of our consumer product development philosophy," said Goldman Sachs Chairman and CEO David M. Solomon.