At about 4:45 a.m., the man was in Terminal 3 when he attempted to board a Spirit Airlines flight without a boarding pass.
When officers stopped him, he attacked and struck two Chicago police officers and two Transportation Security Administration agents.
The man's intentions were unclear. He apparently was unarmed.
He was not charged Sunday night, and it was unclear whether he could face federal or state charges. When he was taken into custody, he was taken to Presence Resurrection Hospital for a mental evaluation.
A Chicago police officer sustained injuries to the face and was transported to Resurrection Hospital for treatment. A Chicago police sergeant was treated on the scene for a laceration to the ear.
The incident comes two days after a deadly shooting rampage at the Ft. Lauderdale airport, killing five people. Estaban Santiago, 26, was a former serviceman who had a history of mental health issues.
It is the latest of several violent incidents at airports around the world.
Security experts said an incident like this cause an airport to shut down, which did not happen at O'Hare.
"A security breach can cause maximum disruption," said Joe Schwieterman, a DePaul University professor and security expert.
Schwieterman said: "There was not only a security breach, but there was a scene of violence, a bit of an assault on a security person. That could lead to changes at checkpoints, longer lines."
Some passengers are worried.
"It definitely gives me some concern and I hope we can do some things to tighten up our security and maybe do some mental health checks," said traveler Kaitlyn McGinnis.
"They are doing it to try and instill fear so people don't travel, I guess they might be accomplishing that with some people. But realistically, we're relatively safe, we're a lot safer than we were 10 years ago," said traveler Thaddeus Wong.