Hawaiians have been told by civil rights campaigners not to travel to Texas because of a controversial immigration law.

The American Civil Liberties Union (ACLU) said the new law unfairly targets undocumented Mexican immigrants in the state.

Texas Governor Greg Abbot signed the law, referred to as Senate Bill 4, that allows police to check the immigration status of individuals during routine traffic stops in an effort to reduce illegal immigration.

The signing into law of the Texas bill follows Donald Trump's repeated promise to build a nearly 2,000 mile (3,218 km) wall along the US-Mexico border.

Lorella Praeli, ACLU director of immigration policy and campaigns, said the concern for Hawaiians was that many of them “fit the racial profile that the police in Texas will use to enforce Trump’s draconian deportation force”.

“Hawaii residents travelling to Texas need to be prepared for illegal harassment,” said Mateo Caballero, legal director of ACLU Hawaii, in a statement.

Hawaii is the most diverse state in the US, with the majority of the population identifying as non-white on the latest census.

The new Texas law also prohibits local jurisdictions from passing any regulations that would exempt them from the state law.

Under the law, police officers refusing to assist federal officials in deportation efforts can be prosecuted.

In 2010, the ACLU issued a similar travel warning when Arizona passed it's own immigration law.