EU migrants who come to the UK as Brexit nears may not be given the right to stay, David Davis has said.
The new Brexit secretary told Sky News there might have to be a cut-off point if there was a "surge" in new arrivals.
But he said setting a date now could in itself prompt a "rush" of people moving before any deadline - and any steps must be compatible with EU law.
It comes amid pressure on the government to guarantee the right to stay to EU citizens already in the UK.
Follow the latest developments on our live page
Ministers have said it would be "unwise" to fully "guarantee" EU citizens' rights without a reciprocal deal for Britons living in other EU countries.
'Beat the deadline'
Mr Davis, who was appointed by the new prime minister, Theresa May, to oversee the negotiations on the UK's exit from the European Union, said he wanted to secure a "generous settlement" for both EU nationals in the UK, and British citizens abroad.
"We have to do it all together," he told Sky News' Murnaghan programme, saying that this stopped "anybody being used as bargaining counters".
He added: "If we make a very generous settlement as I'd like to do, then people are going to say, 'Oh but then that'll attract lots more people in because they want to beat the deadline.'
"And so what I've said is, let's deal with that issue when we come to it. One way of dealing with it could be saying 'Ok, only people who arrived before a certain date get this protection' - there are other ways too.
"But we've got to do it within the law as it stands because at that point we'll still be within the European Union."
EU migrants may face 'right to stay' curbs - David Davis - BBC News