David began his career with Ballina Town in his hometown before making the move to Ipswich Town in September 2007. He spent four seasons an Ipswich Town player before being released in June 2011.
Cawley signed for Sligo Rovers on 22 February 2012. He was given the number 22 shirt upon his arrival at the Showgrounds. He made his debut as a half-time substitute against Glentoran in a 2-0 Setanta Sports Cup victory on 5 March. David scored his first goal for the club with a fine 20 yard strike in a 3-0 home win against reigning champions Shamrock Rovers. As the season went on, Cawley proved to be one of Sligo Rovers‘ most influential players as they claimed the league title. He was nominated for PFAI Young Player of the Year at the end of the season but was pipped by Christopher Forrester. He continued to be a key player in 2013 starting the first 21 league games and only missing two all season. He also finished as second highest scorer behind Anthony Elding. 2014 he scored his first goal in the Europa League, a second leg 4-0 home win against Banga of Lithuania. Sligo was knocked out in the next round against Rosenborg of Norway, having put in a man of the match performance in a 2-1 away win to the Norwegian Giants, they lost at home 3-1.
In 2015, he went on to captain Sligo in a poor season, that kept them safe from relegation. Scored his first of the season against Longford Town, a long range volley into the top corner.
Cawley signed for Dublin side St Patrick’s Athletic on 1 December 2015. Despite winning the 2016 League of Ireland Cup, it was a poor season for Cawley and Pats and he signed for Galway United after just one season at the club.