Please enable JavaScript to use regex101
Regular
Expressions
101
Support Regex101
Social
Info
Regex Editor
Community Library
Account
Regex Quiz
Order By
Most Recent
Most upvotes
Most downvotes
Highest Score
Lowest Score
Filter by Flavor
PCRE2 (PHP)
JavaScript
Python
Golang
Java
.NET 7.0 (C#)
Rust
POSIX ERE
POSIX BRE (grep/sed)
PCRE (Legacy)
Sponsors
digidib · when security, quality, and reliability matter
Community Library
Search community submissions...
0/512
2
Validate color with grb group
Created
·
2026-02-03 03:22
Updated
·
2026-02-04 03:36
Type
·
Match
Flavor
·
Golang
match: #aabbcc #abc (255,255,255) (255,255,255,255) 255,255,255 no match: #gggggg #ggg 256,256,256
Submitted by
Doyoung
1
Check valid URI Scheme according to RFC2396
Created
·
2026-01-17 07:52
Type
·
Match
Flavor
·
Golang
Simple prefix matcher for validating URI Schemes according to [RFC2396, Section 3.1]( http://www.faqs.org/rfcs/rfc2396.html#3.5:~:text=well%20as%20%22http%22%29.-,scheme%20%20%20%20%20%20%20%20%3D%20alpha%20*%28%20alpha%20%7C%20digit%20%7C%20%22%2B%22%20%7C%20%22%2D%22%20%7C%20%22.%22%20%29,-Relative%20URI%20references) Go Playground: https://go.dev/play/p/vtYEugsNAfo
Submitted by
Gwyneth Llewelyn
1
1
Created
·
2025-07-09 00:30
Updated
·
2025-07-09 00:33
Type
·
Match
Flavor
·
Golang
https://regex101.com/r/hIak43/1
Submitted by
1
1
Alpha
Created
·
2025-06-08 16:09
Type
·
Match
Flavor
·
Golang
W alpha/
Submitted by
Furkan
1
ip with port
Created
·
2025-02-16 23:19
Type
·
Match
Flavor
·
Golang
Parse the typical connection string address like 123.123.123.123:123, supports the correct port and octet range
Submitted by
Anonymous
1
advent of code 2024 day3
Created
·
2024-12-04 02:37
Updated
·
2024-12-05 03:15
Type
·
Match
Flavor
·
Golang
regex of challenge
Submitted by
Marcell Martini
1
Validate a comma separated list of IPv4 addresses, CIDRs, or IPv4 Ranges like 1.1.1.1-1.1.1.10
Created
·
2024-11-03 21:59
Type
·
Match
Flavor
·
Golang
Simple Regex to *validate * (no extraction!) an IPv4 Range which can be a comma separated mixture of IPv4 addresses IPv4 CIDRs IPv4 Ranges like 1.1.1.1-1.1.1.10 Examples : 192.168.1.1,255.255.255.255/32,10.10.10.10/24,0.0.0.0/24 192.168.1.1/32 192.168.1.1 192.168.1.1/32 192.168.1.1/12 192.168.1.1/24 192.168.1.1/24 192.168.1.1/0,192.168.1.1/0 10.0.0.0/24 172.16.0.1-172.16.0.255 192.168.1.1,10.0.0.1/24,172.16.0.1-172.16.0.10 64.33.232.212 64.33.232.210/24
Submitted by
alucab
1
ISO 8601 DURATION - Terraform Validation
Created
·
2024-10-10 22:19
Type
·
Match
Flavor
·
Golang
This is made to validate an ISO 8601 input in a Terraform variable validation block: validation { condition = can(regex("^P(\\d+Y)?(\\d+M)?(\\d+D)?(T(\\d+H)?(\\d+M)?(\\d+S)?)?$", var.value)) error_message = "The value must be a valid ISO 8601 duration string representing time. (e.g. PT1M, PT1H30M, PT30S, etc.)" }
Submitted by
Anonymous
1
Slash Separated Numbers
Created
·
2024-10-08 18:12
Type
·
Match
Flavor
·
Golang
...
Submitted by
Anonymous
1
Split Docker image into image name, tag and digest with all optional
Created
·
2024-08-27 08:22
Type
·
Match
Flavor
·
Golang
Splits a Docker image string into the separate parts: image, tag, digest tag and digest are optional
Submitted by
Roemer
1
Kafka loki parser
Created
·
2023-10-24 21:34
Type
·
Match
Flavor
·
Golang
Kafka loki parser
Submitted by
Anonymous
1
0x28C6A6DdF8fF8A47A90A69bfE75cd89904a14d71
Created
·
2023-09-02 02:02
Type
·
Match
Flavor
·
Golang
0x28C6A6DdF8fF8A47A90A69bfE75cd89904a14d71
Submitted by
Anonymous
2
Mikrotik firewall logs
Created
·
2023-08-11 19:09
Updated
·
2023-08-11 21:09
Type
·
Match
Flavor
·
Golang
Matching for mikrotik ROS 7 Used in promtail and grafana
Submitted by
Anonymous
0
Catch packages from 'tdnf list' output
Created
·
2023-06-26 18:42
Type
·
Match
Flavor
·
Golang
Every valid line will be of the form: . . . NOTE: the distribution tag is expected to start with at least one letter and be followed by at least one digit.
Submitted by
Anonymous
1
Home
Created
·
2023-05-13 08:42
Type
·
Match
Flavor
·
Golang
Dj dus er geen je een je aan je enige eerst een he we er
Submitted by
Webmaster
1
extract <*n or <n where n is a number
Created
·
2023-05-11 14:37
Type
·
Match
Flavor
·
Golang
see https://stackoverflow.com/questions/76228402/regex-to-extract-n-where-n-is-digit
Submitted by
code_monk
1
Authelia regex path rules
Created
·
2023-05-06 19:29
Updated
·
2023-05-07 13:35
Type
·
Match
Flavor
·
Golang
Testing Authelia subdomain / path rules. You can read more at the Authelia Docs By default, this regex101 page is shown a test for a generic API path domain: "some-sub.drpranavmishra.com" resources: "^/api([/?].*)?$" # API paths "^/healthz.*$" # Health check "^/\?[\S]{40,70}$" # PrivateBin policy: bypass`
Submitted by
Pranav Mishra
0
Get digits
Created
·
2023-05-03 18:20
Type
·
Substitution
Flavor
·
Golang
Trying to get digits
Submitted by
Arthur Silva
0
walter1976LastClean
Created
·
2023-05-02 03:52
Type
·
Substitution
Flavor
·
Golang
walter1976LastClean
Submitted by
Anonymous
0
匹配限定后缀名的文件,忽略大小写
Created
·
2023-04-26 14:47
Type
·
Match
Flavor
·
Golang
匹配.mka后缀名的文件,忽略大小写
Submitted by
Anonymous
0
匹配限定后缀名中的指定关键字,忽略大小写
Created
·
2023-04-26 14:31
Updated
·
2023-04-26 14:38
Type
·
Unit Tests
Flavor
·
Golang
匹配.mkv和.mp4后缀名中包含menu或sp或.sample,忽略大小写
Submitted by
Anonymous
2
golang re2 negative lookahead
Created
·
2023-04-21 10:28
Type
·
Unit Tests
Flavor
·
Golang
Aquivalent solution for golang's unsupported negative lookahead in re2 flavor of go's regex. This example provides a negative lookahead similar to (?!/api/) ignoring routes with the /api/ prefix at the start.
Submitted by
misha
0
pxc plcnext
Created
·
2023-03-27 07:38
Type
·
Match
Flavor
·
Golang
plcnext version strings
Submitted by
Anonymous
0
domain
Created
·
2023-03-12 10:30
Type
·
Match
Flavor
·
Golang
ss
Submitted by
sssssss
0
Semver split
Created
·
2023-03-10 10:10
Type
·
Substitution
Flavor
·
Golang
"1.2.3" Group 1: 1 Group 2: 2 Group 3: 3
Submitted by
Icaruk
0
Kt SDK V2
Created
·
2023-02-13 15:50
Updated
·
2023-02-14 14:37
Type
·
Match
Flavor
·
Golang
kt SDKV2
Submitted by
Anonymous
0
GO SDK V2
Created
·
2023-02-13 14:23
Updated
·
2023-02-14 14:22
Type
·
Match
Flavor
·
Golang
Go SDK v2
Submitted by
Anonymous
0
REACT SDK V3
Created
·
2023-02-13 10:15
Type
·
Match
Flavor
·
Golang
React SDK V3
Submitted by
Anonymous
0
Anime Xdcc Name + Episode Regex
Created
·
2023-02-11 04:28
Type
·
Match
Flavor
·
Golang
Parse XDCC filename strings for a name and episode. Appears to work for most major bots but unreliable for any data other than name and episode number/version
Submitted by
Anonymous
0
log timestamp
Created
·
2023-01-30 15:42
Type
·
Match
Flavor
·
Golang
extract time stamp from log entry
Submitted by
Anonymous
0
RE2 match of APRS-IS header information
Created
·
2023-01-07 18:33
Type
·
Match
Flavor
·
Golang
This re2 (using Go in my case) matches the APRS-IS header. The format of the APRS-IS packet is TNC2 standard: SOURCE>DESTINATION,PATH:PACKET This regex matches the Q construct format used by APRS-IS: `SOURCE>DESTINATION,PATH,QCON,FROMCALL: The result is a series of capturable groups: Group 1: Src SSID Group 2: Dest SSID Group 3: Path Group 4: Q construct Group 5: From Calll
Submitted by
Jack Hamm (jack@wv6l.net)
0
Golang Get variables In Js
Created
·
2023-01-06 18:06
Type
·
Match
Flavor
·
Golang
To get
Submitted by
Anonymous
0
Date String ISO Pattern
Created
·
2022-12-19 15:16
Type
·
Match
Flavor
·
Golang
Date String ISO Pattern matcher
Submitted by
Lucas Morais
0
VLAN ID Validation Regex
Created
·
2022-12-09 13:32
Type
·
Match
Flavor
·
Golang
VLAN ID Validation Regex Please use first segment or second depending on the Extended VLAN usage such as "1-256" or "1-4096" : Non-extended VLAN IDs (1-256), check v2 of the regex entry ^(25[0-6]|(2[0-4]|1\d|[1-9])\d|[1-9])$ Extended VLAN IDs (1-4096), check v3 of the regex entry ^(409[0-6]|(40[0-8]|[1-3]\d\d|[1-9]\d|[1-9])\d|[1-9])$
Submitted by
ulgena
0
IPv4 Address Validation Regex
Created
·
2022-12-09 13:08
Updated
·
2022-12-09 13:09
Type
·
Match
Flavor
·
Golang
IPv4 Address Validation Regex
Submitted by
ulgena
0
super regex
Created
·
2022-11-26 10:38
Type
·
Match
Flavor
·
Golang
Get every word ending with dot using Regex/VBA
Submitted by
Anonymous
0
Terraform Service Name
Created
·
2022-11-10 23:37
Type
·
Match
Flavor
·
Golang
Useful for validating services in TF
Submitted by
Nick Zaccardi
1
Get project name from git url
Created
·
2022-09-26 13:58
Type
·
Match
Flavor
·
Golang
Used by Zarf to obtain the name of a repository when given a git URL.
Submitted by
Jonathan Perry
0
S3 Path with ending .json
Created
·
2022-09-15 14:38
Type
·
Match
Flavor
·
Golang
S3 Path with ending .json
Submitted by
Sowmith
0
Ruby Gemspec Versioning
Created
·
2022-08-30 13:09
Type
·
Match
Flavor
·
Golang
Determine the version value in a gemspec configuration file
Submitted by
Ori
1
1
Created
·
2022-08-26 15:36
Type
·
Substitution
Flavor
·
Golang
11
Submitted by
Anonymous
0
Match Date From DateTime ISO 8601
Created
·
2022-08-22 10:50
Type
·
Match
Flavor
·
Golang
Match Date From DateTime ISO 8601
Submitted by
kuyaninja
1
nginx access regex loki
Created
·
2022-07-28 11:51
Type
·
Match
Flavor
·
Golang
nginx access log regex
Submitted by
Lethisa Putri
0
oracle_package_new_type
Created
·
2022-07-27 07:20
Type
·
Match
Flavor
·
Golang
find/replace oracle package body new type
Submitted by
Anonymous
0
Letras, número e traço
Created
·
2022-07-26 13:49
Type
·
Substitution
Flavor
·
Golang
Substitui tudo que não for letra, número e traço
Submitted by
Anonymous
0
匹配邮箱
Created
·
2022-05-23 06:48
Type
·
Match
Flavor
·
Golang
[A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)
Submitted by
Lintao
0
Mikrotik Regex Firewall Log Golang
Created
·
2022-05-18 12:47
Type
·
Match
Flavor
·
Golang
Regex para uso com Grafana Loki Log feito via Mangle, com prefix $user do freeradius.
Submitted by
Vitor Abbade
0
String length pattern
Created
·
2022-05-10 05:23
Type
·
Match
Flavor
·
Golang
Simple search of string length with the regexp
Submitted by
Anonymous
0
Golang Docker matcher
Created
·
2022-04-28 18:42
Type
·
Match
Flavor
·
Golang
Used by me for docker-retagger
Submitted by
Roman Minebaev
0
Jira issue number
Created
·
2022-04-26 09:50
Type
·
Match
Flavor
·
Golang
Matches and catches Jira issue number
Submitted by
Anonymous
Load More
Community Library Entry
0
Regular Expression
Open Workspace
/
^
(
[
a
-
zA
-
Z0
-
9
]
+
)
\.
(
jpg
|
png
|
gif
|
bmp
|
pdf
)
/
Description
Created
·
2016-09-25 10:53
Type
·
Match
Flavor
·
PCRE (Legacy)
no description available
Submitted by
4B1D F4DL14N N
Open Workspace