Democratic candidate Deedra Abboud, 45, came under attack after she posted a campaign message on Facebook with an image of the US Constitution.
The post prompted an onslaught of cyberbullying, including comments about Ms Abboud’s religion.
Mr Flake, 54, expressed his support for Ms Abboud on Twitter.
“Hang in there @deedra2018. Sorry you have to put up with this. Lots of wonderful people across AZ. You’ll find them,” he tweeted on Tuesday.
The senator also posted a link to an op-ed in The Arizona Republic calling out the online attack on Ms Abboud, which came after she posted a message about separation of church and state.
“Almost 250 years ago a group of dreamers came together and sketched out a revolutionary vision. No longer would they be shackled to the whims of a distant government, nor bound to the religion of an idiosyncratic king. They set out to forge their own futures, determine their own destinies, and follow their own faith,” she wrote.
“In their infinite wisdom, the Founding Fathers decreed that this nation would separate church and state, and in doing so protect both institutions. Government would be free from religious overreach, and religion would be free from government interference.”