Donald Trump’s nominee for the Supreme Court has described the president’s attacks on the judiciary as “demoralising” and “disheartening”.
Neil Gorsuch’s comments were made to a Democratic senator and confirmed by his spokesman.
The president called a judge who halted his controversial travel ban a “so-called judge”, and said any terror attacks on US soil would be his fault.
The ban on arrivals from seven mainly Muslim countries faces a legal test.
Judge James Robart made headlines last week when he issued a stay on the president’s refugee and immigration ban.
Mr Trump’s reaction was swift.
He tweeted: “The opinion of this so-called judge, which essentially takes law-enforcement away from our country, is ridiculous and will be overturned!”
Later he said that a high school student could see that the president’s ban was lawful.
Senator Richard Blumenthal of Connecticut revealed the conversation with Mr Gorsuch after meeting the Supreme Court nominee on Wednesday.
The federal judge, Mr Blumenthal said, found the president’s criticism to be “demoralising and disheartening”.
Analysis – Anthony Zurcher, BBC News, Washington
Donald Trump has offered Neil Gorsuch the keys to the kingdom – a lifetime appointment to the US Supreme Court, where the 47-year-old judge would have the opportunity to make a lasting mark on American jurisprudence.
The gift comes at a price, however. Mr Gorsuch, highly regarded for his judicial temperament and sharp legal mind, is now in the uncomfortable position of having to explain why the president who nominated him seems intent on eroding the authority of the judicial branch in which he serves.
While past presidents have questioned judicial decisions, Mr Trump – with his “so-called judge” tweet and warnings of assigning blame to courts for future terrorist attacks – has made his disagreements personal.
Now we have evidence that Mr Gorsuch may not hold his tongue and play the loyal soldier. In the end, he has a reputation to protect – one that will outlive the upcoming confirmation battle.
This is the Trump dilemma for conservatives in a nutshell. The president offers Republicans the opportunity to achieve goals long delayed after eight years of Democratic rule. They may not enjoy the political journey the president takes them on to get there, however.