President Trump pledged to eliminate the national debt within eight years. Almost halfway to his self-imposed deadline, it has actually increased.

The U.S. is $3 trillion more in debt than it was when Mr. Trump entered the White House. In nearly three years, it rose 15% — from $19.9 trillion to $22.9 trillion, according to the latest numbers from the Treasury Department.

But Mr. Trump, a Republican, can claim a small victory: The nation's debt has risen at a slower pace under him than under recent presidents.

Get Breaking News Delivered to Your Inbox

At the same point in their presidencies, the debt increased 41% under Democrat Barack Obama, 20% under Republican George W. Bush and 19% under Democrat Bill Clinton. Mr. Obama came into office shortly after the start of the worst recession since the Great Depression in which tax revenues plummeted.

A billboard showing the national debt and each American's share is displayed on September 24, 2019, in downtown Cleveland, Ohio. Getty

The federal deficit has also been growing, recently hitting its highest point in seven years. When the government spends more each year than it receives in tax revenue, it has to borrow, which adds to the national debt.

The federal deficit is $984.4 billion — up 26% from $779 billion in 2018 — and is widely expected to exceed $1 trillion this year. The increase is largely attributed to the $1.5 trillion tax cuts that Mr. Trump signed in 2017. They have so far resulted in revenue losses at a time of spending growth.

The president and Republicans argued that the tax cuts would pay for themselves, but Representative Kevin Brady, who helped craft the 2017 bill, admitted this year that that has yet to happen.

The federal government's debt and deficit are likely to grow as Republicans push for tax cuts and Democrats advocate for increased spending, especially on health care.

Mark Knoller contributed to this report.