While this chemical-free hack has been around for a while, it has gained a cult following in the Mrs Hinch Cleaning Tips Facebook group.
The members of the group, which is based on English cleaning influencer Sophie Hinchcliffe's many home tips, have shared how the hack has transformed their homes.
One woman said she hasn't "seen a fly for weeks" since trying it, while another said it worked like magic.
"I have no idea how or why this utter witchcraft works, but it does!" one person wrote.
"We live on a working farm and two days ago were being driven nuts by big buzzy flies, put this up and they have literally vanished. Not even dead on window sills just vanished!" another person shared.
It's unclear exactly how the bag works to stop flies, but some have hypothesised that it could be due to the light reflected from the coins.
"My research found that the millions of molecules of water presents its own prism effect and given that flies have a lot of eyes, to them it's like a zillion disco balls reflecting light, colours and movement in a dizzying manner," one online commenter said.
"When you figure that flies are prey for many other bugs, animals, birds, etc, they simply won't take the risk of being around that much perceived action."
How to get rid of fruit flies
If it's fruit flies that are the issue in your house, you could try this handy two-ingredient trick that went viral last year.
Using lemon and some cloves, Australian woman Ninny Kriesch explained that all you need to do is cut the ends of a lemon off and then in half so it can sit in a dish.
Ninny then pokes a bunch of cloves into the lemon flesh to release a "fairly strong, pleasant" smell which she assumes is "what keeps the flies away".
Then all you have to do is gently squeeze the lemon once a day to release the juice.
The lemon will last up to six days and the plate can be kept near where you are trying to prevent the fruit flies from gathering.