Built for developers who work with SQL Server and want a lightweight admin interface without standing up SSMS, Azure Data Studio, or a separate admin stack.
Drop staple.php next to your application, enter your connection details, and you have a complete SQL Server admin in under a minute. Full T-SQL type support — identity columns, uniqueidentifier, money, datetime2, nvarchar(max) — all handled automatically.
Browse across databases and schemas, insert and edit records, run raw T-SQL queries, and export results to CSV or JSON — without touching a line of code.
Everything you need to manage SQL Server from PHP
Full table CRUD
Browse, insert, edit, and delete records across any database and schema in SQL Server.
Browse, insert, edit, and delete records across any database and schema in SQL Server.
Schema-aware
Detects T-SQL column types, identity columns, computed columns, and foreign keys.
Detects T-SQL column types, identity columns, computed columns, and foreign keys.
T-SQL type support
Native handling of uniqueidentifier, datetime2, money, nvarchar(max), and all SQL Server types.
Native handling of uniqueidentifier, datetime2, money, nvarchar(max), and all SQL Server types.
Per-column rules
Customize labels, hints, readonly fields, and hidden columns via config.php.
Customize labels, hints, readonly fields, and hidden columns via config.php.
CSRF protection
All write operations are protected by token-based CSRF validation.
All write operations are protected by token-based CSRF validation.
Driver required
Requires the Microsoft PHP Driver for SQL Server (pdo_sqlsrv). No Composer, no other dependencies.
Requires the Microsoft PHP Driver for SQL Server (pdo_sqlsrv). No Composer, no other dependencies.
Up in under a minute
Download
Grab the zip or the bare PHP file below.
Upload
Drop staple.php anywhere on a PHP 8.2+ server with pdo_sqlsrv installed.
Connect
Open it in a browser, enter your SQL Server credentials, and go.
Check your inbox — your download link is on the way.
When to reach for STAPLE
Linux & Mac Development Without SSMS
SQL Server Management Studio is Windows-only, leaving Linux and Mac developers without a native admin interface. STAPLE runs anywhere PHP runs — drop it on your local dev server and get full CRUD access to SQL Server without a VM, Wine, or a remote Windows box. One file, one config, and you’re querying in minutes.
Staging Data Verification
Before a release, QA needs to inspect and sometimes correct staging data without involving a DBA or standing up a full GUI toolchain. STAPLE gives them a schema-aware interface that understands your column types, respects your per-column rules, and exports any result set to CSV or JSON for spot-checking against expected values.
Client & QA Access Without SQL Server Tools
Handing a client or QA analyst a connection string and a copy of SSMS is rarely practical. STAPLE lives behind your existing web authentication and gives non-developers a clean, browser-based interface for viewing and editing records — no software to install, no driver configuration, no SQL knowledge required to navigate tables and make approved edits.
Quick Data Fixes on Windows Servers
Remote Desktop and SSMS add friction when you just need to correct a bad record on a production or staging Windows server. STAPLE is already deployed and accessible through the browser — find the row, edit the field, save it. CSRF protection keeps the interface safe to expose over an authenticated connection without additional tooling overhead.
How it compares
STAPLE isn’t a replacement for a full SQL client — it’s the tool you reach for when those clients aren’t available, aren’t practical, or aren’t appropriate to hand to a non-developer.
SQL Server Management Studio (SSMS)
SSMS is the definitive SQL Server GUI — it handles query plans, profiling, agent jobs, and deep server administration that STAPLE doesn’t attempt. But it’s Windows-only, requires a full installation, and can’t be handed to a client or QA analyst without significant setup. STAPLE covers the 90% case of browsing tables and editing records from any browser, on any OS, with no installation.
Azure Data Studio
Azure Data Studio is a solid cross-platform query editor and works well for developers comfortable writing T-SQL. It still requires a local installation and connection credentials, making it impractical for sharing access with non-technical stakeholders. STAPLE trades the query editor for a zero-install, browser-based interface that non-developers can use immediately — with per-column access rules to keep them in bounds.
DBeaver
DBeaver is a capable universal database client that supports SQL Server alongside dozens of other engines. Like SSMS and Azure Data Studio, it’s a desktop application — every person who needs access has to install it, configure a driver, and manage their own connection. STAPLE requires nothing on the client side; whoever can reach your web server can use it, with access scoped by your config.
Frequently asked questions
-
Microsoft publishes official installation guides for Linux (Ubuntu, Alpine, RHEL) and Windows on the SQL Server PHP driver documentation page. On Ubuntu you install the
php-sqlsrvandphp-pdo-sqlsrvpackages from Microsoft’s package repository; on Windows you download the DLL from PECL and add it to yourphp.ini. STAPLE checks for the extension at startup and surfaces a clear error if it’s missing. -
STAPLE works with SQL Server 2012 and later, including SQL Server 2016, 2017, 2019, 2022, and Azure SQL Database. The T-SQL type awareness — identity columns,
uniqueidentifier,datetime2,money,nvarchar(max)— relies on standard system catalog views that have been stable since SQL Server 2012. Azure SQL is fully supported; Synapse Analytics and SQL Server 2008 or earlier are not tested. -
STAPLE runs on both. Windows hosting with IIS or Apache and the Microsoft PHP SQL Server driver is the most common enterprise deployment — it’s the configuration where
pdo_sqlsrvis easiest to install. Linux hosting works equally well once the Microsoft ODBC driver and PHP extension are in place. The single-file design means there’s nothing to compile or build; copystaple.phpandconfig.phpto your web root and it runs. -
In
config.php, set theservervalue toHOSTNAME\INSTANCENAMEfor a named instance, orHOSTNAME,PORTfor a specific TCP port — both follow standardpdo_sqlsrvDSN syntax. If your instance uses dynamic ports, specify the resolved port rather than relying on the SQL Server Browser service, which may not be reachable from your PHP host. -
STAPLE is released under the Elastic License 2.0 (ELv2). You can use it freely for internal tooling, client projects, and self-hosted applications. The restriction is that you may not provide STAPLE as a managed service to third parties — meaning you cannot resell access to STAPLE itself as a hosted product. For the vast majority of development and admin use cases, ELv2 imposes no practical restriction.
-
STAPLE reads the schema catalog before rendering the insert form and automatically excludes identity columns from the input — you won’t see a field for them and they’re never included in the
INSERTstatement, so SQL Server assigns the value as normal. After a successful insert, STAPLE retrieves the generated identity value viaSCOPE_IDENTITY()and redirects to the newly created row so you can verify the result immediately.