Deputy Prime Minister Barnaby Joyce has blamed NSW Premier Mike Baird's decision to ban greyhound racing from July 1 next year for swings against the Coalition in the state's local council elections.

Sydney lord mayor Clover Moore claimed a record fourth term in a strong result for the independent, while Labor claimed large swings towards it in the western Sydney local government areas of Liverpool, Penrith, the Blue Mountains, Blacktown, Campbelltown and Camden.

The elections come a month after Mr Baird's controversial ban, which was opposed by some state National Party MPs, was passed into law.

Mr Joyce, the leader of the federal National Party, told the ABC's Insiders program the local government result contained a stern lesson for the Coalition.