I used to be able to encrypt JS files and filenames and send over Gmail. But I just found I cannot do it anymore and it is saying there are executables found in the compressed file. How could Gmail detects file contained in an encrypted package with filenames also encrypted? And is there any workaround?

Update: After reading the answer in the post provided by @Blind Spots, it seems like no encrypted file can be send (I also tried myself).

  • 1
    The solution I found was wetransfer.com
    – Nick
    Nov 23, 2021 at 16:36
  • @Nick That is a horrible idea.
    – user279568
    Nov 23, 2021 at 17:25
  • @Gantendo why? It works.
    – Nick
    Nov 23, 2021 at 17:53
  • @Nick It is rather inconvenient compared to the method I posted below. WeTransfer is full of ads and trackers. WeTransfer is also quite buggy.
    – user279568
    Nov 23, 2021 at 18:13
  • Easy, rename the exe extension to something like jpg, it will send now. Receiver has has to rename them back.
    – Moab
    Nov 23, 2021 at 23:07

1 Answer 1


I have encountered the same problem and didn't find any workaround for it. Gmail is now much more strict about attachments.

My solution was to upload the file to some online service, in my case Dropbox, and transmit instead a shared link to the file. Note that the generated link should be as anonymous as possible and the file should be uploaded to a publicly accessible section of your online service storage.

  • 1
    @Gantendo: Google Drive is a specific example of the recommendation made by harry "upload the file to some online service, and transmit instead a shared link to the file"
    – Ben Voigt
    Nov 23, 2021 at 19:24
  • I see this option. However I am expecting a more direct way, i.e. not depending on other applications. But I do not want to manipulate too much, e.g. revert the binaries and output to a txt as hexadecimals. I will accept your answer if no better approach answered. Nov 24, 2021 at 1:17
  • @BenVoigt Difference is that it is built in and doesn't require you to switch to a new tab and share your file with yet another company.
    – user279568
    Nov 24, 2021 at 4:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.