The $1tr (£770bn) agreement to keep the US government running until 30 September was reached on Sunday night.
While there was no money for a wall, Republicans managed to secure $1.5bn in spending on border security.
Lawmakers are expected to vote on the package in the coming days. Full details are yet to be made public.
The deal comes after Congress approved a temporary spending bill that averted a government shutdown at the weekend.
That gave Congress one more week to work out federal spending for the last five months of the fiscal year.
The failure to act would have closed national parks and monuments and left hundreds of thousands of government employees without pay.
The last shutdown, in 2013, lasted for 17 days.
What about Trump's wall?
White House demands for the spending bill to include a down payment on a barrier along the southern border have come to naught.
The $1.5bn for border security in the new budget comes with key caveats.
The Trump administration can only spend the money on repairs to existing fencing, infrastructure and technology, according to US media.
Nor has the administration succeeded in its plan to eliminate funding for so-called US sanctuary cities, which shelter undocumented immigrants.
However, Mr Trump insists he will still get money for his key campaign promise in a new spending bill this autumn.
The Republican president told a rally in Pennsylvania on Saturday night: "We'll build the wall, people, don't even worry about it."
What are the wins for Democrats?
Democrats say they torpedoed from the spending bill 160 policy measures, known as riders, that they labelled "poison pills".
According to reports, none of Mr Trump's calls for $18bn in non-defence cuts are included.
Democrats also fended off potential cuts to Planned Parenthood, a family-planning group abhorred by social conservatives because it provides abortions.
The 1,600-page spending bill reportedly gives retired coal miners $1.3bn in health benefits, a priority of two Democratic senators.
Democrats have also secured $295m to help Puerto Rico continue making payments to the Medicaid health insurance programme for the poor, and $100m to combat opioid addiction.
And New York Democrats secured $61m of funding to reimburse law enforcement agencies for the cost of protecting Mr Trump when he travels to his residences in Florida and New York.
Furthermore, the deal increases funding for the National Institutes of Health, despite the Trump administration's calls to reduce the medical research agency's budget.
Last week, Democrats also wrung from the White House a concession that the bill would not target subsidies paid to insurers to keep Obamacare costs down for low-income patients.
Democratic Senate leader Chuck Schumer said in a statement. "The bill ensures taxpayer dollars aren't used to fund an ineffective border wall, excludes poison-pill riders, and increases investments in programs that the middle-class relies on."
What are the wins for Trump?
President Trump has won $12.5bn in extra funding for defence spending.
However, that falls short of the $30bn sought by his budget blueprint.
The spending package would save him and congressional Republicans the embarrassment of presiding over a government shutdown.
"We couldn't be more pleased," US Vice-President Mike Pence said in an interview on CBS This Morning.
But Jim Jordan, chairman of the House of Representatives Freedom Caucus, said he and fellow hardline conservatives were "disappointed".
Republicans control the Congress, Senate and White House, but Democratic votes are still needed to pass the bill.
|In 2013, the government did shut down in a row over healthcare. GETTY IMAGES|
Congress reaches deal to keep government open through September
Congressional negotiators reached an agreement late Sunday on a broad spending package to fund the government through the end of September, alleviating fears of a government shutdown later this week, several congressional aides said.
Congress is expected to vote on the roughly $1 trillion package early this week. The bipartisan agreement includes policy victories for Democrats, whose votes will be necessary to pass the measure in the Senate, as well as $12.5 billion in new military spending and $1.5 billion more for border security requested by Republican leaders in Congress.
The agreement follows weeks of tense negotiations between Democrats and GOP leaders after President Trump insisted that the deal include funding to begin building a wall along the U.S.-Mexico border. Trump eventually dropped that demand, leaving Congress to resolve lingering issues over several unrelated policy measures.
The new border-security money comes with strict limitations that the Trump administration use it only for technology investments and repairs to existing fencing and infrastructure, the aides said.
“This agreement is a good agreement for the American people and takes the threat of a government shutdown off the table,” said Senate Minority Leader Charles E. Schumer (D-N.Y.). “The bill ensures taxpayer dollars aren’t used to fund an ineffective border wall, excludes poison pill riders and increases investments in programs that the middle class relies on, like medical research, education and infrastructure.”
Schumer and House Minority Leader Nancy Pelosi (D-Calif.) boasted that they were able to force Republicans to withdraw more than 160 unrelated policy measures, known as riders, including those that would have cut environmental funding and scaled back financial regulations for Wall Street.
Democrats fought to include $295 million to help Puerto Rico continue making payments to Medicaid, $100 million to combat opioid addiction, and increases in energy and science funding that Trump had proposed cutting. If passed, the legislation will ensure that Planned Parenthood continues to receive federal funding through September.
The package includes $61 million to reimburse local law enforcement agencies for the cost of protecting Trump when he travels to his residences in Florida and New York, a major priority for the two New York Democrats involved in the spending talks, Schumer and Rep. Nita M. Lowey.
Among the bipartisan victories is $407 million in wildfire relief for western states and a decision to permanently extend a program that provides health-care coverage for coal miners.
“The agreement will move the needle forward on conservative priorities and will ensure that the essential functions of the federal government are maintained,” said Jennifer Hing, a spokeswoman for House Appropriations Committee Chairman Rodney Frelinghuysen (R-N.J.).
House Republicans have struggled in recent weeks to keep their members focused on spending as White House officials and conservatives pressed leaders to revive plans for a vote on health-care legislation. The health-care fight became tangled last week in spending talks as leaders worried that forcing a vote to repeal the Affordable Care Act risked angering Democrats whose votes are necessary to avoid a government shutdown.
Leaders worked last week to determine whether the House has enough votes to pass a revised health-care bill brokered by the White House, the head of the conservative House Freedom Caucus and a top member of the moderate Tuesday Group.
House Speaker Paul D. Ryan (R-Wis.) and his top lieutenants announced Thursday that they did not have sufficient votes to be sure the measure would pass but vowed to press on.
“We’re still educating members,” House Majority Leader Kevin McCarthy (R-Calif.) told reporters after a late-night health-care meeting last week. “We’ve been making great progress. As soon as we have the votes, we’ll vote on it.”
Congress has reached a budget deal to fund the federal government through September
WASHINGTON (Reuters) — U.S. congressional negotiators have hammered out a bipartisan agreement on a spending package to keep the federal government funded through the end of the current fiscal year on Sept. 30, a senior congressional aide said on Sunday.
The House of Representatives and Senate must approve the deal before the end of Friday and send it to President Donald Trump for his signature to avoid the first government shutdown since 2013.
The Washington Post reported that Congress was expected to vote early this week on the agreement that is expected to include increases for defense spending and border security.
The Republican-led Congress averted a U.S. government shutdown last Friday by voting for a stop-gap spending bill that gave lawmakers another week to work out federal spending over the final five months of the fiscal year.
Congress was tied up for months trying to work out $1 trillion in spending priorities for the current fiscal year. Lawmakers were supposed to have taken care of the fiscal 2017 appropriations bills by last Oct. 1.
Democrats backed Friday's stop-gap bill a day after House Republican leaders again put off a vote on major healthcare legislation sought by Trump and opposed by Democrats to dismantle the 2010 Affordable Care Act, dubbed Obamacare, after Republican moderates balked at provisions added to entice hard-line conservatives.
Trump earlier bowed to Democratic demands that the spending legislation for the rest of the fiscal year not include money to start building a wall along the U.S.-Mexico border he said is needed to fight illegal immigration and stop drug smugglers.
The Trump administration also agreed to continue funding for a major component of Obamacare despite Republican vows to end the program.