President Donald Trump has signed a law that will impose sanctions on any firm that helps Russia’s state-owned gas company, Gazprom, finish a pipeline into the European Union.
The sanctions target firms building Nord Stream 2, an undersea pipeline that will allow Russia to increase gas exports to Germany.
The US considers the project a security risk to Europe.
Both Russia and the EU have strongly condemned the US sanctions.
Congress voted through the measures as part of a defence bill last week and the legislation, which described the pipeline as a “tool of coercion”, was signed off by Mr Trump on Friday.
The almost $11bn (£8.4bn) Nord Stream 2 project has infuriated the US, with both Republican and Democratic lawmakers opposing it.
The Trump administration fears the pipeline will tighten Russia’s grip over Europe’s energy supply and reduce its own share of the lucrative European market for American liquefied natural gas.
President Trump has said the 1,225km (760-mile) pipeline, owned by Russia’s Gazprom, could turn Germany into a “hostage of Russia”.
The US sanctions have angered Russia and the European Union, which says it should be able to decide its own energy policies.
Earlier this week German Chancellor Angela Merkel said she was “opposed to extraterritorial sanctions” against the Nord Stream 2 project.
German foreign minister Heiko Maas struck a more combative tone, saying the sanctions amounted to “interference in autonomous decisions taken in Europe”.
Allseas, a Swiss-Dutch company involved in the project, said it had suspended its pipe-laying activities in anticipation of the sanctions.
The US sanctions also target TurkStream, a Russia-Turkey pipeline, and include asset freezes and revocation of US visas for the contractors.
On Saturday, the EU voiced its clear opposition to the US sanctions.
“As a matter of principle, the EU opposes the imposition of sanctions against EU companies conducting legitimate business,” a spokesman for the trading bloc told AFP news agency.
Russia’s foreign ministry also strongly opposed the move, with ministry spokeswoman Maria Zakharova accusing Washington of promoting an “ideology” that hinders global competition.
The consortium behind Nord Stream 2 confirmed that it would build the pipeline as soon as possible, despite the sanctions.
It said: “Completing the project is essential for European supply security. We, together with the companies supporting the project, will work on finishing the pipeline as soon as possible.”
For years EU member states have been concerned about the bloc’s reliance on Russian gas.
Russia currently supplies about 40% of the EU’s gas supplies – just ahead of Norway, which is not in the EU but takes part in its single market. The new pipeline will increase the amount of gas going under the Baltic to 55 billion cubic metres per year.
Disagreements among EU nations were so strong that, earlier this year, they even threatened to derail the project entirely.