"We don't always get that opportunity to stand and applaud the men and women who keep us safe," the president said. "But they're out there, hundreds of thousands of you, patrolling our streets every single day. And we know that when we need you most, you'll be ready to dash into danger, to protect our lives even if it means putting your lives on the line.
"That's what these folks are all about. That's what the men and women standing behind me have proven -- their heart, their courage, their dedication."
Obama recounted the bravery of some of the honorees, including Brian Murphy of Wisconsin, the first officer to arrive when a gunman opened fire on a congregation in a temple.
"He fought back until help arrived and ordered his fellow officers, who are here today, to protect the safety of the Americans worshiping inside -- even though he was lying there bleeding from 12 bullet wounds," Obama said. "When he was asked how he did it, he said, 'That's just the way we're made.'
"That's what you've got to do. That's what you've got to be made of to take down homicide suspects in Los Angeles or Vegas, or shooters in Miami or Indiana or Chicago or Iowa -- saving untold numbers of lives. That's what you've got to be made of to dodge live power lines during Hurricane Sandy to free your partner pinned down by a tree, all the while saying, 'I've got you, pal.'
"Yes, this is their job. But it's not just about the uniform that they wear. It's about who they are, what they're made of. When a gunman entered a restaurant in Pasadena, Texas, it was three off-duty cops who put themselves in harm's way so that others could escape.
"Detective Ivan Marcano didn't care that he was off-duty when he saw two muggers attacking a cab driver in the Bronx. He got out of his girlfriend's car to stop them and was shot point blank in the chest, a bullet inches from his heart. But his story doesn't end there. As his girlfriend was driving him to the hospital -- I'm sure not very happy with him -- by total coincidence, they ran into the shooter's getaway car.
"So what does Detective Marcano do? He jumps out of the car -- he's been shot -- keeps pressure on his chest with his left hand, holding a service weapon with his right, he runs after the suspects. He took one of them down, which led to the capture of the others. He wasn't on the clock when any of this happened. This was his date night. It's unbelievable."
Obama then asked Marcano's girlfriend to stand.
"She deserves a really nice dinner after putting her through that," the president said to laughter.
"So today, to all our Top Cops, let me say that our nation shares that sense of gratitude. You embody America at its best and at its bravest."
Obama made an oblique reference to the issue of gun control, saying leaders must focus on "making it harder for dangerous criminals to get their hands on lethal weapons."
Swim Week Miami Beach 2014 [PHOTOS]