Get the Django Forms Builder demo running in under 5 minutes!
./setup.shsetup.batThat's it! The script will:
- ✅ Install Python dependencies
- ✅ Install the forms_builder package
- ✅ Create database tables
- ✅ Load 3 example forms
- ✅ Prompt for admin credentials
python manage.py runserverBeautiful landing page with:
- Feature overview
- Quick links to builder and admin
- Getting started guide
URL: http://127.0.0.1:8000/admin
Login with the credentials you created during setup.
Things to try:
- View the 3 pre-loaded forms
- Create a new form
- View form submissions (after filling some forms)
- Edit form properties
Contact Form: http://127.0.0.1:8000/renderer/contact-form/
- Simple single-step form
- Name, email, and message fields
- Real-time validation
Registration Form: http://127.0.0.1:8000/renderer/registration-form/
- Multi-step wizard (3 steps)
- Progress indicator
- Step-by-step navigation
Survey Form: http://127.0.0.1:8000/renderer/survey-form/
- 2-step customer satisfaction survey
- Rating system (1-5)
- Optional feedback
URL: http://127.0.0.1:8000/builder/
Visual form builder interface.
Note: For full functionality, build the frontend components first:
cd .. # to forms-poc root
npm install
npm run build:builder-
Go to http://127.0.0.1:8000/admin/forms_builder/formdefinition/add/
-
Enter:
- ID:
my-first-form - Title:
My First Form - Description:
Testing the form builder - Check Is active
- ID:
-
Paste this JSON in the Definition field:
{ "id": "my-first-form", "title": "My First Form", "description": "A simple test form", "isMultiStep": false, "steps": [{ "id": "step-1", "title": "Information", "order": 0, "fields": [{ "id": "name", "type": "text", "name": "name", "label": "Your Name", "placeholder": "Enter your name", "required": true, "validation": [{ "type": "required", "message": "Please enter your name" }] }, { "id": "email", "type": "email", "name": "email", "label": "Email Address", "placeholder": "you@example.com", "required": true, "validation": [{ "type": "required", "message": "Email is required" }, { "type": "email", "message": "Please enter a valid email" }] }] }] } -
Click Save
-
View your form: http://127.0.0.1:8000/renderer/my-first-form/
-
Build the frontend components:
cd .. # to forms-poc root npm run build:builder
-
Open the builder: http://127.0.0.1:8000/builder/
-
Drag fields from the palette
-
Click fields to edit properties
-
Click "Export Form JSON"
-
Import the JSON to admin (see Method 1, step 3)
- ✅ Run setup script
- ✅ View the 3 example forms
- ✅ Submit a test form
- ✅ Check submissions in admin
- ✅ Create a simple form in admin
- ✅ Test your form in the renderer
- ✅ Add validation rules
- ✅ View your submissions
- ✅ Create a multi-step form
- ✅ Add conditional logic
- ✅ Test the API endpoints
- ✅ Customize the templates
curl http://127.0.0.1:8000/forms/api/forms/contact-form/curl -X POST http://127.0.0.1:8000/forms/api/forms/contact-form/submit/ \
-H "Content-Type: application/json" \
-d '{
"name": "John Doe",
"email": "john@example.com",
"message": "Test submission from API"
}'curl -X POST http://127.0.0.1:8000/forms/api/forms/contact-form/validate/ \
-H "Content-Type: application/json" \
-d '{
"name": "John Doe",
"email": "invalid-email"
}'-
Go to http://127.0.0.1:8000/admin/forms_builder/formsubmission/
-
Click on any submission to see:
- Form data in a nice table format
- Submission timestamp
- User information
- IP address
Templates are in demo_project/templates/:
base.html- Base layout with navigationhome.html- Home pageforms/builder.html- Builder pageforms/renderer.html- Renderer page
Add custom CSS in the templates or create static CSS files.
Edit the inline styles in templates/base.html to match your brand.
Solution: Create a superuser:
python manage.py createsuperuserSolution:
- Check form ID in the URL matches the database
- Ensure the form is marked "Is active" in admin
- Reload fixtures:
python manage.py loaddata demo_project/fixtures/example_forms.json
Solution: Build the components:
cd .. # to forms-poc root
npm install
npm run build:allSolution: Reset the database:
rm db.sqlite3
python manage.py migrate
python manage.py createsuperuser
python manage.py loaddata demo_project/fixtures/example_forms.json-
Explore the Admin: The Django admin is fully customized for forms management
-
Check the Console: Open browser DevTools to see validation and API calls
-
Try Multi-Step: The registration form shows off the wizard functionality
-
Test Validation: Try submitting forms with invalid data to see validation in action
-
View Raw JSON: In admin, look at the "Definition Preview" to see the form structure
Once you're comfortable with the basics:
- Read the full README for detailed documentation
- Check out GETTING_STARTED.md for the complete project guide
- Learn about conditional logic
- Explore NL Design System integration
- Check the full README
- Review the troubleshooting section
- Examine the example forms in
demo_project/fixtures/ - Look at the Django admin for validation errors
You now have a fully functional form builder system. Create, test, and iterate on your forms!
Ready to dive deeper? → Read the Full Documentation