Metadata-Version: 2.1
Name: mojo-compiler
Author: Modular Inc
Author-email: hello@modular.com
Home-page: https://modular.com
License: LicenseRef-MAX-Platform-Software-License
Description-Content-Type: text/markdown
Summary: The Mojo programming language (compiler only)
Project-URL: Changelog, https://docs.modular.com/mojo/changelog
Project-URL: Discord, https://discord.com/invite/modular
Project-URL: Documentation, https://docs.modular.com/mojo/
Project-URL: Forum, https://forum.modular.com/c/mojo
Project-URL: Issues, https://github.com/modular/modular/issues
Project-URL: Source, https://github.com/modular/modular/tree/main/mojo
Version: 0.25.6.1

<h1 align="center">
    <img
      src="https://modular-assets.s3.amazonaws.com/images/mojo_github_logo_bg.png?20250905"
      alt="Mojo">
</h1>

<div align="center">

  [Get started] | [API docs] | [Changelog] | [GitHub]

</div>

[Get started]: https://docs.modular.com/mojo/manual/get-started/
[API docs]: https://docs.modular.com/mojo/lib
[Changelog]: https://docs.modular.com/mojo/changelog
[GitHub]: https://github.com/modular/modular/tree/main/mojo

Mojo is a systems programming language specifically designed for
high-performance AI infrastructure and heterogeneous hardware. Our vision for
Mojo is to be the one programming language developers need to target diverse
hardware—CPUs, GPUs, and other accelerators—using Python's intuitive syntax
combined with modern systems programming capabilities. Of course, Mojo also
provides strong [interoperability with
Python](https://docs.modular.com/mojo/manual/python/).

**NOTE:** Not available for Windows.

## What's in `mojo-compiler`

The `mojo-compiler` package includes the minimal dependencies required to build
and run Mojo code, such as the Mojo compiler and standard library. It's smaller
than the full [`mojo` package](https://pypi.org/project/mojo/) package and it's
useful for environments where you only need to execute Mojo code. For example,
`mojo-compiler` is good if you want it just to run Mojo in a production
environment or when you're programming in Python and calling into a Mojo
package (but not writing new Mojo code).

The `mojo-compiler` **doesn't include** the Mojo language server (LSP), LLDB
debugger tools, Mojo code formatter, or Mojo REPL. For a complete developer
installation, we recommend the [`mojo` package](https://pypi.org/project/mojo/)
package instead.

## Get started with `pip`

1. Install Mojo:

    ```sh
    pip install mojo-compiler
    ```

    If you want the nightly build, instead use:

    ```sh
    pip install --pre mojo-compiler \
      --index-url https://dl.modular.com/public/nightly/python/simple/
    ```

2. Write some code:

    ```mojo
    # hello.mojo
    def main():
      print("Hello, World!")
    ```

3. Run the code:

    ```sh
    mojo hello.mojo
    ```

    ```output
    Hello, World!
    ```

Using `pip` is great for existing Python-based environments, but if you're
getting started for the first time, we recommend instead installing with
`pixi`. For more information, see the [Mojo install
guide](https://docs.modular.com/mojo/manual/install).

