Welcome to pyxpo
pyxpo is an open-source framework for building native iOS, Android, Mac and Windows apps, and web apps, in Python. If you know React Native or Expo, you already know how it works.
You write screens as Python functions that return components. State lives in hooks. Files in the app/ folder become routes. pyxpo runs your code in a real CPython 3.13.7 interpreter inside the app and draws real UIKit and Android views. There is no web view. The same code also runs as a native desktop app and, through Pyodide, in the browser.
from pyxpo import Text, View
def Index():
return View(Text("Hello from Python"), style={"padding": 24})
default = IndexWhat you get
- Components and APIs with React Native names:
View,Text,FlatList,Alert,Platform,Linkingand many more. - Hooks:
useState,useEffect,useReducer,useContextand the rest, plususe_asyncfor async work. - Themes and responsive layout: light and dark themes in
StyleSheet.create, breakpoints in any style, andContainer,Row,ColandGridlayouts. - A file-based router with Stack, Tabs and Drawer layouts, dynamic routes and deep links.
- Native modules as pip packages, for photos, files, secure storage, sharing and more.
- App config in
pyproject.tomland config plugins in Python, so you rarely need to touch native files. - One CLI to create, run with hot reload, build, and prebuild native projects, for iOS, Android, desktop and web.
pyxpo 0.1.0a5 is an alpha release. The API follows Expo and React Native closely, but some details may change before 1.0. Please report problems on GitHub.
Where to go next
Create your first app
Install, scaffold and run on a device.
Components and APIs
The building blocks of every screen.
Styling and themes
StyleSheet, light and dark themes, dynamic styles.
Responsive layout
Breakpoints, Container, Row, Col and Grid.
Router
File-based navigation with layouts.
Native modules
Camera, files, storage and sharing.
App config
Icons, splash, permissions, plugins.
Web
The same app in the browser, on any static host.
Desktop apps
Native Mac and Windows apps.
How it works
CPython, the reconciler and the bridge.