Lua Pattern Tester
![]()
A live web tool for testing, understanding, and debugging Lua/Luau patterns in your browser.
Useful for debugging or experimenting with patterns without repeatedly running scripts in Studio.
Visit Website | GitHub
Example
Pattern:
^/(%a+)%s+(%w+)%s*(%d*)$
Text:
/ban Player123 60
Captures:
Introduction
Hello everyone!
I initially built this a few years ago for personal use because I couldn’t find a dedicated live Lua pattern tester, and recently gave it a major overhaul. Some of my friends and I have been using it for things like parsing logs, game databases, debugging, experimenting with patterns, etc. Thought it might be useful for some of you too!
I’m open to any feedback!
Why this exists
Lua/Luau patterns are useful, but debugging them can be slow and annoying. This tool helps you try patterns, inspect captures, experiment with complex patterns, and understand what each part of a pattern is doing. You can use it for things like parsing chat commands, datastores, input validation, and more.
Features
- Pattern Testing: Run and experiment with your Lua/Luau patterns and test strings through
match,gmatch,find, andgsub. - Pattern Breakdown: A custom parser that explains what your pattern is actually doing (captures, classes, etc).
- Real-time Highlighting: See matches immediately as you type.
- Save/load: Save/load your patterns and test strings.
- Capture Viewer: View exact string and position captures in color-coded cards
- Responsive Design: A responsive and simple user interface that’s easy on the eyes.
- Quick Reference: A small cheat sheet built right into the UI.
- Runs in-browser: Open Source and no text or patterns are sent anywhere.
Usage
- Enter a Lua pattern.
- Enter a test string.
- Choose the Lua function and inspect the output, captures, and explanation.
Tech Stack
Built with React, Vite, and fengari-web (Lua VM). Styling is all custom Vanilla CSS. If you want to contribute to the project, refer to the GitHub Repo.
If you run into issues or have feedback, I’m happy to help.

