Skip to content

offerrall/FuncToWeb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Func To Web 0.9.2

PyPI version Python Tests License

Type hints → Web UI. Minimal-boilerplate web apps from Python functions.

func-to-web Demo

Quick Start (30 seconds)

pip install func-to-web
from func_to_web import run

def divide(a: float, b: float):
    return a / b

run(divide)

Open http://127.0.0.1:8000You have a working web app!

Demo

Complete Feature Overview

Complete documentation with examples and screenshots for each feature:

Input Types

Output Types

  • Images & Plots: Return PIL Images and Matplotlib figures
  • File Downloads: Return FileResponse for any file type
  • Tables: Return list[dict], list[tuple], Pandas, NumPy, or Polars DataFrames
  • Multiple Outputs: Return tuples/lists combining text, images, tables, and files

Features

  • Authentication: Username/password protection
  • Function Descriptions: Display docstrings in the UI
  • Dark Mode: Automatic theme switching
  • Server Options: Custom host, port, path and more
  • Large Files: Optimized streaming (GB+ files)
  • Progress Bars: Real-time upload/download tracking
  • Error Handling: Beautiful error messages

Full Documentation API Reference

Perfect For

  • Rapid Prototyping - From pure Python function to usable web interface in seconds.
  • Image Processing - Upload, process, and download images with PIL/Pillow.
  • Data Science & Reporting - Instantly publish Pandas/Polars DataFrames and matplotlib plots without frontend code.
  • Secure Internal Apps - Admin panels, dashboards, and team tools protected by built-in authentication.
  • Production Deployments - Docker-friendly, supports Nginx/Traefik reverse proxies, SSL, and high-performance streaming.

Quick Examples

Check the examples/ folder for 20 complete examples (Covers all features)

Requirements

Core:

  • Python 3.10+
  • FastAPI, Uvicorn, Pydantic, Jinja2, python-multipart, itsdangerous

Optional (for extended functionality):

  • Pillow, Matplotlib, Pandas, NumPy, Polars

Development:

  • pytest, mkdocs, mkdocs-material

Run Tests

pytest tests/ -v

Deploy Docs

mkdocs gh-deploy

MIT LicenseMade by Beltrán Offerrall • Contributions welcome!

About

Minimal-boilerplate web apps from Python functions.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published