Google is banning Javascript attachments from Gmail

Looking at you, Javascript.
 By 
Anisa Purbasari
 on 
Original image replaced with Mashable logo
Original image has been replaced. Credit: Mashable

Google has announced that it will soon prohibit users from sending Javascript files over email, according to a post on the official blog for GSuite, Google's business and enterprise tools.

In the name of security, Gmail will begin a permanent ban on attachments with .js file extensions on Feb. 13, 2017. If you try to send a Javascript attachment after that date, you'll get a prompt that the message is blocked for security reasons.

Original image replaced with Mashable logo
Original image has been replaced. Credit: Mashable

Currently, Google restricts certain attachments from being sent over Gmail to protect users from potential viruses. Other file extensions that are prohibited include .exe, .jse, .ade and .adp.

Recently, .js files have been used to carry out malicious cyberattacks. Last year, a vulnerability in Yahoo Mail gave hackers the opportunity to embed malicious .js code in emails. Once a user opened his or her email, the code would start working and allow the hacker to hijack the user's account. In April of last year, Microsoft also noticed that many spam campaigns were using .js attachments.

Users who still want to share .js files within Google's ecosystem will still be able to do so via other means, such as Google Drive and Google Cloud Storage.

Mashable Image
Anisa Purbasari

Anisa was a Tech News Intern for Mashable, based in New York. She recently graduated with an MA in Journalism from New York University and her bylines have appeared in Fusion, Business Insider and The Verge. Before taking the plunge into journalism, she worked briefly as a telecommunications, technology and media lawyer in New Zealand.

Mashable Potato

Recommended For You
You can now change your Gmail username. Here’s how to do it.
Gmail logo on mobile device

Gmail launches AI inbox and overviews with Gemini
Gemini logo displayed on a smartphone with Gmail logo in the background

The Epstein Files: Read Epstein's emails as if you hacked into his Gmail with Jmail
Jmail World


Elon Musk's X bans 'InfoFi' crypto projects for posting AI slop and reply spam
X logo on mobile device

Trending on Mashable
NYT Connections hints today: Clues, answers for April 3, 2026
Connections game on a smartphone

Wordle today: Answer, hints for April 3, 2026
Wordle game on a smartphone

What's new to streaming this week? (April 3, 2026)
A composite of images from film and TV streaming this week.


Google launches Gemma 4, a new open-source model: How to try it
Google Gemma
The biggest stories of the day delivered to your inbox.
These newsletters may contain advertising, deals, or affiliate links. By clicking Subscribe, you confirm you are 16+ and agree to our Terms of Use and Privacy Policy.
Thanks for signing up. See you at your inbox!