Code file extensions
Source code and script files used for software development and automation workflows.
Total extensions in this category: 33
Extensions in Code
Explore the most searched extensions in this category.
- .php
PHP script (PHP source code)
.php files typically contain PHP source code used on web servers to generate dynamic web pages and API responses. You can open them in a code editor, but they are usually executed by a web server (often via PHP-FPM) rather than “run” like a normal desktop app.
- .sql
SQL script (Structured Query Language)
.sql files contain SQL statements (queries, schema definitions, and data changes) that can be run by a database tool or opened as plain text for review and editing.
- .cs
C# source code file
.cs files contain C# source code used to build .NET applications and libraries. They are plain-text files typically edited in code editors and IDEs such as Visual Studio Code with C# tooling.
- .go
Go source file
.go files contain source code written in the Go (Golang) programming language. You can open them in code editors (for reading/editing) or build/run them with the Go toolchain.
- .tsx
TypeScript JSX (TSX) source file
.tsx is a TypeScript source code file that contains JSX syntax, commonly used with React-style UI components. You open it in a code editor (for viewing/editing) and build it with TypeScript tooling (for running in apps).
- .kt
Kotlin source file
.kt files contain Kotlin source code used to build Kotlin applications (including Android apps) and libraries. You typically open them in a code editor or IDE such as IntelliJ IDEA or Android Studio.
- .swift
Swift Source Code
.swift is a Swift programming language source file used to write apps and other software. You open it in code editors and IDEs such as Xcode or other text/code editors.
- .dart
Dart source code
.dart files contain source code written in the Dart programming language. You open them in a code editor/IDE or work with them using the Dart SDK tools.
- .proto
Protocol Buffers schema (Protocol Buffers definition file)
.proto files define data structures and services for Google’s Protocol Buffers. They are plain-text schemas that you open in a text editor/IDE or compile with the Protocol Buffers compiler (protoc) to generate code.
- .cjs
CommonJS Module File
.cjs is a JavaScript source file that Node.js always interprets as a CommonJS module. It’s commonly used in projects that otherwise default to ES modules, to force a specific file to use CommonJS semantics.
- .gql
GraphQL Document (operations and fragments)
.gql files typically store GraphQL query/mutation/subscription documents (and fragments) used by GraphQL clients, servers, and developer tools. You can open them in any text editor, and many GraphQL editor/LSP tools recognize .gql for syntax features.
- .graphql
GraphQL Schema/Query Document (SDL)
.graphql files are plain-text GraphQL documents commonly used to store GraphQL schema definitions (SDL) and sometimes operations (queries/mutations). They open in code editors and IDEs with GraphQL language support.
- .kts
Kotlin Script
.kts is a Kotlin script source file used to run Kotlin code as a script. It can be opened in code editors and executed with the Kotlin command-line compiler.
- .lua
Lua source code (Lua script)
.lua files contain Lua source code used as scripts or modules in Lua-based applications and embedded systems. You can open them in a text editor or run them with a Lua interpreter when available.
- .cc
C++ source file
.cc most commonly refers to a C++ source code file. You open it in a code editor or IDE, and you can compile it with a C++ compiler such as GCC (g++).
- .hh
HH source file
.hh is most commonly a C++ header source file used to declare interfaces (functions, classes, constants) for C++ programs. You open it with a text editor or an IDE, not a document viewer.
- .js
JavaScript File
.js files hold JavaScript (ECMAScript) source as plain text. In practice you either edit them in a code editor or run them with a runtime (typically Node.js on servers/desktops, or a browser when the file is loaded as a web script)—not with vague “any app that supports the format” defaults.
- .pl
PL source file
.PL most commonly refers to a Perl script/source code file. You can open it in any plain-text editor, and run it with a Perl interpreter on desktop operating systems.
- .py
Python Script File
.py files are plain-text Python source. You edit them in an IDE or editor; you execute them with the python3 interpreter (or py on Windows), usually inside a virtual environment when a project lists dependencies—much more specific than “install any compatible application.”
- .sh
Shell script
.sh files are usually shell script files (text programs) meant to be run by a Unix-like command interpreter such as sh or bash. You can open them in any text editor, but running them will execute commands on your system.
- .ts
TypeScript file
.TS files are primarily associated with TypeScript files used in web development and can be opened with code editors on various platforms.
- .cpp
C++ source file
.CPP files are C++ source code files used in software development. You open them in a code editor or an IDE, and you compile them with a C++ compiler (for example, GCC or Visual Studio).
- .cxx
C++ source file
.cxx is most commonly a C++ source code file (an implementation file). You open it with a code editor or IDE, and you compile it with a C++ compiler such as g++.
- .hpp
C++ header
.HPP is most commonly a C++ header file (plain text) used in programming projects. You open it with a code editor or IDE such as Visual Studio, Xcode, or many other text editors.
- .hxx
HXX source file
.hxx is most commonly a C++ header source file used in programming projects. You open it with a code editor or an IDE (not a document viewer).
- .mjs
JavaScript module file
.mjs is a JavaScript (ECMAScript) module source file. You open it with a code editor to view/edit, or run it with a JavaScript runtime such as Node.js.
- .rb
RB source file
.rb most commonly means a Ruby source code file (Ruby script). Open it in a text editor or IDE, or run it with the Ruby interpreter.
- .rs
Rust source file
.rs most commonly means a Rust source code file. It can also appear in standards-based XML contexts via the registered media type application/rls-services+xml, so you may need to confirm the file’s origin.
- .tcl
TCL source file
.tcl is most commonly a Tcl (Tool Command Language) script stored as plain ASCII text. You can open it in a text editor, or run it with a Tcl interpreter such as tclsh.
- .ea
Expert Advisor File
EA files are used in trading platforms to automate trading strategies.
- .wat
WebAssembly Text Format (WAT)
.wat is the human-readable text format for a WebAssembly module. You can open it in a code editor, or convert it to a runnable .wasm binary using WebAssembly tooling such as WABT.
- .java
Java source file
.java is a Java source code file (a compilation unit) used to write Java programs. You open it with a code editor or IDE, and you compile it with a Java compiler such as javac to produce .class bytecode.
- .cs1
Custom Script Format
CS1 files are custom script files used in specific applications for automation or configuration purposes.