NPR has terminated its contract with Juan Williams, one of its senior news analysts, after he made comments about Muslims on the Fox News Channel.

NPR said in a statement that it gave Mr. Williams notice of his termination on Wednesday night.

The move came after Mr. Williams, who is also a Fox News political analyst, appeared on the “The O’Reilly Factor” on Monday. On the show, the host, Bill O’Reilly, asked him to respond to the notion that the United States was facing a “Muslim dilemma.” Mr. O’Reilly said, “The cold truth is that in the world today jihad, aided and abetted by some Muslim nations, is the biggest threat on the planet.”

Mr. Williams said he concurred with Mr. O’Reilly.

He continued: “I mean, look, Bill, I’m not a bigot. You know the kind of books I’ve written about the civil rights movement in this country. But when I get on the plane, I got to tell you, if I see people who are in Muslim garb and I think, you know, they are identifying themselves first and foremost as Muslims, I get worried. I get nervous.”