TechOps Workbench
SQL SERVER · TRANSACT-SQL QUERY FORMATTING

Give your query space.
Make the logic easier to read.

Paste a query and format it in your browser. Your original stays intact.

Original query

0 characters

Formatted SQL

Ready to format.

Scope: Transact-SQL query text. Stored procedures, SQLCMD directives and complex procedural scripts are not supported. Formatting is not syntax validation, query analysis or execution.
LOCAL PROCESSING

Your query stays
on this page.

No SQL connection, upload, analytics payload or browser storage is used for query text. Reloading clears your work.

What changes

Spacing, line breaks and your selected keyword case are formatted. Identifier, function and data-type casing are preserved. String literals and comments are handled by the Transact-SQL formatter. Always review output before running it, especially vendor-specific or procedural syntax.

Large or unsupported queries

The input limit is 200,000 characters. Formatting runs separately from the interface; a slow request times out after five seconds. On an error, your original remains available. Editing the input or options clears stale output so you cannot accidentally copy an earlier result.

Formatter version 15.9.0. All formatting assets are served with this site.