O'Brien was born in Jersey City, New Jersey, on March 7, 1879. He attended the Jersey City Public Schools, Academy of St. Aloysius Grammar School and Saint Peter's College. He graduated from Fordham University. He studied law at the New York Law School, was admitted to the bar and commenced practice in Jersey City. He was a judge of the second criminal court, and was director of public safety of Jersey City from 1917 to 1921. He was a delegate to the 1920 Democratic National Convention.