RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find To check a valid IP Address
Expression
\b(?:\d{1,3}\.){3}\d{1,3}\b
Description
To check a valid IP Address. It will check the valid IP address on the logic of three dots max three digits in each section
Matches
192.168.10.210
Non-Matches
192.168.10.256.21
Author Rating: The rating for this expression. Chandan Kumar
Source self
Your Rating
Bad Good

Enter New Comment

Title
 
Name
 
Comment
 
Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Title: wrong positive results
Name: Calamity Jane
Date: 8/13/2015 5:26:21 AM
Comment:
Thinks an ip address like e.g. 300.3.3.3 is valid, which it isn't. So it says "ok" to those whch are ok, but doesn't exclude invalid IPs


Copyright © 2001-2018, RegexAdvice.com | ASP.NET Tutorials