Image caption Alabama's Republican Governor Robert Bentley says he thinks the laws will overcome challenges

The US state of Alabama has passed into law one of the most stringent immigration laws in the country.

The new legislation, similar to one passed last year in Arizona, requires schools to find out if students are there illegally.

The law, which takes effect on 1 September, also make it a crime to give an illegal immigrant a ride in a car.

Advocacy groups say they will challenge the measures, which they call racist and unconstitutional.

There are an estimated 12 million illegal immigrants in the US - and individual states have increasingly taken matters into their own hands in an attempt to tackle the problem.

Fear of deportation

But none has gone so far as Alabama, says the BBC's Jane O'Brien in Washington.

As in Arizona, police will now be allowed to arrest anybody suspected of being an illegal immigrant - even if they are stopped for something else, says our correspondent.

But in addition, businesses and schools will be required to check the legal status of workers and students, while landlords will be committing a crime if they knowingly rent to illegal immigrants.

Republican Governor Robert Bentley, who signed the bill into law Thursday, said: "We have a real problem with illegal immigration in this country.

"I campaigned for the toughest immigration laws, and I'm proud of the legislature for working tirelessly to create the strongest immigration bill in the country."

But an attorney for the American Civil Liberties Union warned the move could deter some immigrant parents from sending their children to school, for fear of arrest or deportation.

A district judge blocked the most controversial parts of Arizona's law - such as wider police stop-and-search powers - amid fears of racial profiling.

That case is expected to end up in the US Supreme Court.