Piracy did not end, but the increased activity of the British Navy caused it to decline in the early 18th century. Still, piracy continued long after the 1720s. Privateering was a factor in every naval war of the period, and that's just dressed-up piracy. The last famous pirate I can think of is Jean Lafitte, who allied himself and his crew with Andrew Jackson to help defend New Orleans in 1815.