The top court in the US has ruled judges in lower courts have limited ability to block presidential orders, giving President Donald Trump what he called a "giant win".

The case surrounded whether Trump's attempt to use an executive order to end birthright citizenship for non-citizens and undocumented migrants was allowed.

In a 6-3 ruling, the Supreme Court's conservative justices sided with Trump and said they were not addressing Trump's attempt to end birthright citizenship. Rather their ruling addressed presidential actions broadly.

Experts said the ruling will change how executive actions are challenged in the future and noted legal challenges to the Friday ruling are likely to come.

Immigrant rights groups and 22 states sued the Trump administration over an executive order the president signed on his first day back in office. That order was aimed at ending birthright citizenship which gives people born on US territory automatic citizenship rights.