This setup is perfect for teams that already rely on MySQL and want to build web apps on top of existing data:
Connect to a MySQL database through a secure API or backend service
Read data from tables to power lists, tables, charts, and dashboards
Create, update, and delete records from forms and workflows
Filter, sort, and paginate results
Work with relational data using joins handled by your backend
Reuse existing schemas without migrating data to a new system
Handle complex CRUD flows without duplicating business logic
Scale from internal tools to customer-facing apps using the same data model
What WeWeb supports natively
Category
Feature
What it does
Data source
SQL plugin for MySQL
Provides a generic SQL data source plugin that can be pointed at a MySQL server (host, port, DB, user, password).
Connection
Direct DB connection config
Stores connection parameters and tests connectivity. Once validated, the MySQL instance becomes an available data source for collections.
Collections
Table/SQL-based collections
Lets you create collections that run SQL queries against MySQL and expose the results as lists/objects usable in repeaters, data grids, etc.
Queries
Custom SQL queries
Supports arbitrary SQL read queries via custom formulas that build parametrized SQL strings, which the SQL plugin then executes.
Parameters
Dynamic query parameters
Encourages using custom JavaScript formulas with parameters (e.g. column, where value) to safely inject dynamic values into SQL queries.
CRUD
Read and write operations
Can be used for SELECT as well as INSERT/UPDATE/DELETE by calling SQL actions from workflows,
enabling inline editing patterns (e.g. Data Grid editing).
Data binding
Bind collection data to UI
Allows binding MySQL collection fields directly into text, inputs, tables, and Data Grid elements, including pagination and inline edit flows.
Joins & combos
Combine with other collections
Works with WeWeb’s “joining data” and formula tools so MySQL result sets can be merged or enriched with data from other sources.
Why use WeWeb with MySQL
WeWeb + MySQL gives you a clean separation between your UI and your data, so you can move fast without compromising structure or security:
An internal admin tool to manage users, orders, or inventory stored in MySQL
A client portal that reads account data and transaction history
A CRM or ERP frontend built on top of a legacy MySQL database
A reporting dashboard with filters, charts, and pagination
A SaaS app frontend connected to a MySQL-powered backend
And more…
Integrating MySQL with WeWeb
Integrating MySQL with WeWeb is straightforward:
In the WeWeb Editor, add a Data Source that points to your backend API connected to MySQL
Configure endpoints for reading and writing data
Bind API responses to collections and UI elements in the WeWeb Editor
Use workflows to handle create, update, and delete actions
Best practices
Design clear API endpoints instead of exposing raw SQL queries
Use pagination and filtering to keep responses fast on large tables
Keep schema changes versioned to avoid breaking frontend bindings
Centralize validation and business logic in the backend when possible
Complex joins and heavy queries should be optimized server-side to maintain performance
FAQs
1. How do I connect a MySQL database to WeWeb?
Add a new SQL data source in the plugins/data sources section and enter your MySQL host, port, database name, username, and password. After testing the connection, the SQL source becomes available when creating collections and actions.
2. How do I query MySQL tables from WeWeb?
Create a SQL collection linked to your MySQL source and provide either a table reference or a custom SELECT query. The collection’s rows then appear as a list you can bind to repeaters, tables, or other UI components.
3. Can I run INSERT/UPDATE/DELETE operations on MySQL from WeWeb?
Yes, SQL actions can execute write queries, which you typically trigger from workflows (e.g., on form submit or Data Grid save). This enables simple CRUD patterns such as inline editing or admin panels backed directly by MySQL.
4. How do I use dynamic filters or search parameters in MySQL queries?
Use a custom JavaScript formula to build the SQL string from parameters (like search text, IDs, or pagination offsets) and feed that string into the SQL collection/action. The formula approach keeps the query configurable while still letting you centralize the logic.
5. Can I join MySQL data with data from other sources inside WeWeb?
Yes, MySQL collections can be combined with other collections (REST, other databases) via the “joining data” features and formulas. This lets you enrich rows from MySQL with related data or computed fields before rendering them.