REGEXVAULTv2.0
$docs--getting-started

REGEXVAULT DOCUMENTATION

Quick Start

RegexVault is a curated library of production-tested regular expressions. Every pattern is audited for correctness, performance, and ReDoS safety before publication.

1.

Browse the library

Visit /library to search and filter across all 417 patterns.

2.

Copy a pattern

Click the copy button on any pattern card to copy the regex to your clipboard. JavaScript implementations are free for everyone.

3.

View the full implementation

Click into any pattern to see the full code implementation, test cases, edge cases, and engine-specific notes.

4.

Test before deploying

Use the live tester on the homepage to validate regex patterns against your own test strings before copying them into your codebase.

API Reference

RegexVault provides a JSON API for programmatic access to the pattern library.

GET/api/patterns

Returns a paginated list of all patterns. Supports search and category filtering.

Query Parameters

q — Search query (fuzzy match on title, description, pattern)

category — Filter by category slug

limit — Results per page (default: 25, max: 100)

offset — Pagination offset

GET/api/patterns/[slug]

Returns a single pattern by its slug, including all language variants, test cases, and metadata.

POST/api/patterns/test

Test a regex pattern against an input string. Returns match results with a 200ms timeout for ReDoS protection.

Request Body (JSON)

pattern — The regex pattern string

flags — Regex flags (e.g., "gi")

input — Test string to match against

POST/api/submit

Submit a new pattern for review. Includes automated verification (schema validation, ReDoS detection, test case execution).

ReDoS Safety

Regular Expression Denial of Service (ReDoS) occurs when a crafted input causes a regex engine to enter catastrophic backtracking, consuming exponential CPU time. A single vulnerable regex in a web server can take down your entire application.

RegexVault takes ReDoS seriously. Every pattern undergoes a two-phase safety audit:

Phase 1

Static Analysis

Patterns are analyzed for known ReDoS-vulnerable constructs: nested quantifiers, overlapping alternations, and ambiguous repetition. Patterns with these "smells" are flagged for additional scrutiny.

Phase 2

Dynamic Stress Testing

Each pattern is executed against adversarial inputs designed to trigger worst-case backtracking. Any pattern that exceeds a 200ms execution threshold is rejected.

Patterns that pass both phases receive the VERIFIED SAFE badge. Patterns that fail either phase are rejected from the library entirely — we do not publish unsafe patterns.

Pro Access

Every pattern is free to browse and copy in JavaScript. Pro unlocks the full multi-engine experience — verified implementations for every language your stack uses, so you're not guessing whether a pattern behaves the same in Python or Go.

All 5 Engine Implementations

JavaScript, Python, Go, Java, and PHP/PCRE for every pattern.

Bookmark Your Patterns

Save and access your most-used patterns from your dashboard.

Priority Submission Review

Get your submitted patterns reviewed within 48 hours.

Pattern Submission

RegexVault accepts community pattern submissions. Every submission goes through automated verification and manual review before publication.

1.

Submit your pattern

Visit /submit and fill out the submission form with your pattern, test cases, and documentation.

2.

Automated verification

Your pattern is automatically tested for schema compliance, ReDoS safety, and test case validity.

3.

Manual review

Patterns that pass automated verification are queued for manual review. Free submissions are reviewed in order. Priority review ($15, one-time) guarantees a response within 48 hours.

4.

Publication

Accepted patterns are enriched with multi-language implementations, documentation, and SEO metadata, then published to the library.