It started as a lone voice for gun control in the Senate, but the message was amplified in real time to millions on Facebook and Twitter.

The term #filibuster was trending on Twitter on Wednesday night and Thursday morning as Senator Christopher S. Murphy of Connecticut and fellow Democrats held the Senate floor, hammering a message about the need for stricter gun control measures in the wake of Sunday’s shooting in Orlando, Fla.

The 15-hour marathon began shortly after 11 a.m. Wednesday when Mr. Murphy interrupted the consideration of an appropriations bill, and ended shortly after 2 a.m. Thursday.

Mr. Murphy began his speech by saying, “I’ve had enough.” He went on to speak at length about the 2012 Newtown shooting in his home state. “I couldn’t just come back to the Senate this week and pretend like this is business as usual.”

He was joined by almost all of his 44 Democratic Senate colleagues, including Richard J. Durbin of Illinois, Claire McCaskill of Missouri, Cory Booker of New Jersey, Elizabeth Warren of Massachusetts and Jeff Merkley of Oregon.

Mr. Merkley shared a personal experience, telling the story of a teenage cousin, Rebecka Ann Carnes, who was killed in a shooting last year at Umpqua Community College in Roseburg, Ore.

“She was a beautiful spirit, but her adventure ended so shortly after graduating from high school, before she could really get started on the journey of life,” he said.

The senators were not always speaking to a full chamber, but they found a significant audience online, with many Twitter users cheering them on with hashtags like #filibuster and #holdthefloor.

But critics questioned the validity of gun control measures in the context of constitutional rights.

Shout out to the Republicans and Dems who didn't join this silly #filibuster to take away our rights.

Mr. Murphy accompanied his speech with a stream of Twitter posts on gun violence statistics and excerpts from his speech.

“How many people have to die before we decide the death toll is too high?” he said in a post early Thursday. “We cannot wait to act.”

Shortly before 2 a.m., Mr. Murphy announced on Twitter that he had achieved what he set out to do: win commitments from Republican leaders that they would hold votes on the gun control measures he wanted. He thanked those who had supported him in phone calls, Twitter posts and emails. About 20 minutes later, the filibuster ended at 2:11 a.m.