A man will appear in court on Tuesday to answer charges that he hopped off his bike to allegedly perform sexual acts on two dogs in a shock attack in Sydney's west.

The man is alleged to have cycled up to two young women walking their dogs through an enclosed bicycle path in the western Sydney suburb of Greystanes last month.

Merrylands Police have arrested a 39-year-old man and charged him with attempted bestiality and committing an act of indecency. Credit:NSW Police

Police will allege he exposed himself to both and assaulted one of their dogs. The pair fled as the man allegedly began to turn and attack another animal.

The 39-year-old man has been charged with bestiality and committing an act of indecency.