A senior Trump appointee at an agency responsible for enforcing laws against financial discrimination faced open rebellion from subordinates Friday over blog posts he wrote years ago expressing controversial views on the n-word and hate crimes, according to internal emails obtained by The Washington Post.

The uproar came as two Democrats on the Senate Banking Committee and a national housing rights organization called for the departure of the appointee, Eric Blankenstein, a policy director at the Consumer Financial Protection Bureau.

The upheaval was triggered by a mass email from a senior civil servant who harshly criticized the writings, which The Post revealed and linked to Blankenstein in a report Wednesday. Writing under a pen name in 2004, Blankenstein questioned whether the n-word was inherently racist and claimed that the great majority of hate crimes were hoaxes.

“The tone and framing are deeply disturbing to me as a woman, African American, advocate for LGBTQ rights, and human being,” Patrice A. Ficklin, a career staffer and director of the Office of Fair Lending and Equal Opportunity, wrote to hundreds of agency employees.

Earlier in the week, Blankenstein asked Ficklin, his subordinate, to write a supportive note about him for The Post’s initial story. In her email Friday, Ficklin said she had not read Blankenstein’s blog when she did so. “After the article appeared, I began to read his posts and was struck by how they reminded me of debates we’ve had with Eric on supervisory and enforcement matters,” she wrote.

“And while he has been collegial, thoughtful and meticulous, I have had experiences that have raised concerns that are now quite alarming in light of the content of his blog posts — experiences that call into question Eric’s ability and intent to carry out his and his Acting Director’s repeated yet unsubstantiated commitment to a continued strong fair lending program under governing legal precedent,” she wrote.

Career employees rallied swiftly around Ficklin, sending supportive emails agency-wide, according to multiple emails obtained by The Post.

The CFPB has been a target of the Trump administration. In February, Mick Mulvaney, its acting director, moved to strip enforcement powers from the fair-lending office — potentially reversing years of aggressive enforcement.

On Friday, shortly after noon, Ficklin shared a copy of her planned email with Blankenstein and other political officials, saying she intended to send it to a wider group.

At 1:38 p.m., Blankenstein wrote an email appealing to her to hold off. Minutes later, the bureau’s chief of staff, Kirsten Sutton, made her own appeal. 

“I am trying to reach you,” Sutton wrote in an email to Ficklin. “Please do not send this until we’ve had the chance to connect.”

Seven minutes later, Ficklin notified Mulvaney and seven other top agency officials that she was proceeding. She hit “send” at 2:01 p.m., a copy of the email shows.

A senior colleague replied to all: “I wholeheartedly support you.”

Dozens of other colleagues then sent bureau-wide notes agreeing with Ficklin’s sentiments. “We, the undersigned members of the Office of Fair Lending and Equal Opportunity, support Patrice Ficklin in her statement,” said an email signed by 17 agency employees.

Bureau spokesman John ­Czwartacki declined to answer questions about the episode or make Blankenstein available for an interview. The bureau said that it “has no plan to make any personnel or policy changes related to this issue.”

Ficklin did not respond to messages seeking comment.

In response to The Post’s report Wednesday, Sen. Sherrod Brown (Ohio), the senior Democrat on the Senate Banking Committee, and Sen. Elizabeth Warren (D-Mass.), the bureau’s former head and a longtime critic of Mulvaney’s leadership, called for Blankenstein’s exit.

“Eric Blankenstein has done everything he can to keep the CFPB from doing its job, gutting the Office of Fair Lending and failing to file a single anti-discrimination lawsuit since he arrived at the agency in December,” Warren said in a statement. “Now we know why — Blankenstein must be fired.”

Brown said the bureau is supposed to be on the “front lines of fighting and preventing predatory lending practices including very real financial discrimination that happens all too often in America today.”

“These blog posts are hateful, reprehensible and disgusting. Placing Blankenstein in charge of fair lending was a serious moral and managerial failure, and he must go,” Brown said.

The National Fair Housing Alliance, which represents some 220 local and state nonprofit housing and civil rights groups, also called for his resignation.

“The National Fair Housing Alliance is appalled that the CFPB has someone that is clearly unequipped to lead the Bureau’s anti-discrimination work or make decisions based on the principles of equality as part of its leadership,” the group said in a statement.

The bureau was created by President Barack Obama after the 2008 financial meltdown.