What is the AS file format?
.as files are associated with the ActionScript programming language, developed originally by Macromedia and later maintained by Adobe Systems.
Files with the .as extension store source code for Flash and Flex applications. An .as file can store instructions and function definitions, as well as variables and references to external or system resources (including system libraries). The source code must be compiled by Adobe Animate, the Apache Flex SDK, or Apache Royale into AVM bytecode embedded inside a .swf file that the Flash Player or AIR runtime executes; opening an .as file directly only reveals the human-readable code.
ActionScript is an object-oriented programming language built on the ECMAScript standard (the same specification underlying JavaScript). ActionScript was primarily used for developing and managing animations, banners, and interactive visual content on websites. ActionScript 3.0, released in 2006 with Flash Player 9, introduced a strict class-based model, a redesigned virtual machine (AVM2), and formal package/import syntax; an AS3 .as file typically begins with a package { } block containing import statements and a public class definition. ActionScript is a full-featured language capable of powering fully functional, interactive, and visually rich web applications, web-based games, forms, and advanced menus.
Adobe Flash reached end-of-life in December 2020, and major browsers removed Flash Player support. New interactive web work now favors JavaScript and TypeScript. The ActionScript language itself survives through the open-source Apache Royale project, which compiles .as and .mxml source files into JavaScript-based output that runs without Flash.
.as files store their content in plain-text format (UTF-8 or ASCII) and can be opened and edited using any text editor. However, it is recommended that .as files be edited with a dedicated tool such as Visual Studio Code (with an ActionScript extension) or Sublime Text, to take advantage of automatic keyword highlighting, syntax error detection, and code completion.
Security & safety
RISK: LOWA .as file is plain-text source code and cannot run on its own, so simply opening it in an editor is safe. The caution is for developers: ActionScript code you compile and run can perform network calls, file access (within the Flash sandbox) and load other assets, so review untrusted .as before compiling and running it - just as with any third-party source code. Beware "free ActionScript decompiler" sites bundling adware; use reputable tools (JPEXS) when extracting AS from a .swf.
Format details
in a nutshell- Applesoft BASIC program - On Apple II emulators, .as can denote an Applesoft BASIC source/listing - unrelated to ActionScript; open in the emulator or a text editor.
- ASCII text / generic source - Some tools use .as for generic ASCII data or assembly source; content is plain text identifiable by inspection.
Programs that open AS files
Technical details
deep spec| Language paradigm | Object-oriented, event-driven; class-based with single class inheritance and multiple interface support (ActionScript 3.0) |
| File encoding | UTF-8 or ASCII plain text; no byte-order mark required |
| MIME type | `text/plain` (primary); also `application/x-actionscript` and `text/x-actionscript` |
| File signature | None - plain text; AS3 files identified by opening `package { }` declaration and `public class` keyword, not a byte signature |
| Target virtual machine | ActionScript 1 and 2 target AVM1; ActionScript 3 targets AVM2; the two VMs are bytecode-incompatible |
| Compilation output | Compiled to AVM bytecode embedded inside a `.swf` container; the `.as` file itself is not directly executable |
| AS3 file structure | Begins with `package { }` block, followed by `import` statements and a `public class` definition containing methods and properties |
| Typical file size | 1 KB - 200 KB per class file; large projects contain many individual `.as` source files |
| Build toolchain | Adobe Animate (formerly Flash Professional), Apache Flex SDK (`mxmlc` compiler), Apache Royale compiler (`asc2`) |
| Related compiled artifacts | `.swf` (deployed application), `.swc` (compiled component library), `.abc` (raw AVM2 bytecode) |
| Platform support | Cross-platform source file; Flex and Royale SDKs compile on Windows, macOS, and Linux |
| Post-Flash status | Adobe Flash Player reached end-of-life December 2020; ActionScript 3 continues via Apache Royale targeting HTML5/JavaScript output |
| ECMAScript conformance | ActionScript 3.0 aligns with the ECMAScript 4 draft; shares syntax with JavaScript but adds static typing and a formal `class` keyword |
| Base class | All AS3 classes implicitly extend `Object`; display-list objects extend `DisplayObject` within the `flash.display` package |
| Released | 1998 (ActionScript 1.0 in Flash 4); ActionScript 3.0 in 2006 (Flash 9/Flex 2) |
| Latest version | ActionScript 3.0 (2006); maintained today via the Apache Royale / Apache Flex SDK |
| Open standard | Yes · royalty-free |
| Specification | en.wikipedia.org |
AS conversions
Community Q&A
asked by usersNo questions yet - be the first to ask about AS files.