Welcome to PHPForm, a fully open-source, headless form builder designed with simplicity, efficiency, and privacy in mind. Built to be easily installed on any budget-friendly hosting solution or free cloud tiers, PHPForm is the perfect choice for developers and businesses looking for a reliable and GDPR-compliant form management solution.
- Headless Architecture: PHPForm is built as a headless server, offering flexibility and ease of integration with various frontend systems.
- Robust Admin Panel: Manage your forms with ease using our user-friendly admin panel, designed for efficient and intuitive form management.
- Cost-Effective: Designed to run smoothly on inexpensive hosting or free cloud services, reducing your operational costs.
- GDPR Compliant: We prioritize your data privacy. PHPForm ensures that all your data remains yours, complying fully with GDPR regulations.
- Browser Push and Email notifications: Get notified when a new form submission is received.
- Captcha Protection: Protect your forms from spam and abuse with different Captcha providers.
- Token-based Protection: Ideal protection for mobile and desktop apps.
- PHP 8.2 or higher.
- GD
- ZIP
- XML
- SQLite
- MySQL
- PostgreSQL
- MariaDB
- AuroraDB
PHPForm is released under MIT, ensuring it remains free and open for use and modification.
Use the latest image from docker hub to run it locally:
docker run --name phpform -d -p 9000:9000 phpform/phpform-server:latest
Copy environment file and adjust it to your needs:
cp .env.prod .env
Run DB migrations from container
docker exec -it phpform bash
php bin/console doctrine:migrations:diff
php bin/console doctrine:migrations:migrate
Make sure you have PHP 8.2 and composer installed. Checkout the repository jump to the folder. Copy environment file and adjust it to your needs:
cp .env.prod .env
Install dependencies:
composer install
Run database migrations:
php bin/console doctrine:migrations:diff
php bin/console doctrine:migrations:migrate
Run the server:
php -S localhost:8000 -t public
Build the project on your local machine or download prebuild release. Upload the files to your shared hosting. Make sure you make "public" folder as your main folder.
You can deploy PHPForm on any cloud hosting provider that supports PHP 8.2 or higher. Also you can use PHPForm Docker Image to deploy PHPForm on any cloud hosting provider that supports docker.
Make sure you:
- Set the environment variable
APP_ENV
toprod
- Set the environment variable
APP_SECRET
to a random string - Set the environment variable
DATABASE_URL
to your database connection string
Copy environment file with default values:
cp .env.prod .env
Please make sure you made /app/var as persistent storage if you use SQLite. If you want to use other database please change DATABASE_URL env variable.
Run database migrations:
php bin/console doctrine:migrations:diff
php bin/console doctrine:migrations:migrate
If you see an error that the vendor folder is missing, you need to install the dependencies.
Warning: require_once(/app/vendor/autoload_runtime.php): Failed to open stream: No such file or directory in /app/public/index.php on line 5
The main problem usually when you run composer install from the root user. If you still want to run composer install from the root user, you can use the following command:
COMPOSER_ALLOW_SUPERUSER=1 composer install
PHPForm is a headless form server. This means that you can use any frontend framework to build your forms. We provide a set of frontend components that you can use to build your forms.
Soon will be available components for React, Vue, Angular, Svelte and more.
Stay in touch with us on Twitter to get the latest updates.