He scored three goals in ten appearances to help the "Blades" win promotion as champions, and was hopeful that manager Chris Wilder would sign him permanently in the summer; ironically his parent club, Chesterfield, were relegated in last place. He was released by Chesterfield upon his return to the Proact Stadium in May 2017. O'Shea turned down a contract offer from Sheffield United, and instead joined League One club Bury on a two-year contract in July 2017. He went straight into the starting eleven for the opening fixture, at home to Walsall, but lasted only 54 minutes before sustaining a medial ligament injury that was expected to keep him out for six weeks. He marked his return to fitness with a goal in a 3–1 victory over Bradford City at Gigg Lane on 14 October. He ended the 2017–18 campaign with four goals in 30 appearances as the "Shakers" were relegated with a last-place finish. On 17 November he scored a brace in a 4–0 home win over Stevenage, including a "perfectly executed freekick", to win himself a place on the EFL team of the week. He was named as EFL League Two Player of the Month for November 2018 and January 2019, and said that "I've only ever won one of these before this season, so to win two in three months is excellent." On 19 January, he scored a "superb solo goal" in a 2–1 win at Forest Green Rovers that saw him again named on the EFL team of the week. On 9 February, he scored a brace in a 3–2 win at Morecambe to earn himself a place on the EFL team of the week for the third time that season. After scoring 15 goals in 44 league games he was named on the League Two PFA Team of the Year for the 2018–19 season, alongside midfield teammate Danny Mayor. Bury went on to secure promotion as runners-up of League Two. In the summer he was strongly linked with a move to Plymouth Argyle, who were managed by former Bury boss Ryan Lowe. On 28 June 2019, O'Shea left England for Australia and signed with A-League club Brisbane Roar, who were managed by former Liverpool striker Robbie Fowler. He made 24 appearances before the 2019–20 season was suspended due to the COVID-19 pandemic in Australia. O'Shea has represented the Republic of Ireland at under-19, under-21, and under-23 levels.